tgsi: initialize ctx.file in tgsi_dump_instruction()
authorBrian Paul <brianp@vmware.com>
Fri, 16 Oct 2015 20:31:22 +0000 (14:31 -0600)
committerBrian Paul <brianp@vmware.com>
Fri, 16 Oct 2015 20:32:09 +0000 (14:32 -0600)
Fixes segfault because of uninitialized file pointer.
Trivial.

src/gallium/auxiliary/tgsi/tgsi_dump.c

index 8ceb5b475843ce8c849607a7299c792011567075..5d80cca5b0e31120fe468a057ccc5c0bd5991f63 100644 (file)
@@ -648,6 +648,7 @@ tgsi_dump_instruction(
    ctx.indent = 0;
    ctx.dump_printf = dump_ctx_printf;
    ctx.indentation = 0;
+   ctx.file = NULL;
 
    iter_instruction( &ctx.iter, (struct tgsi_full_instruction *)inst );
 }