[Mesa-dev] [PATCH] i965: remove redundant NULL check
Timothy Arceri
timothy.arceri at collabora.com
Sat May 21 02:06:58 UTC 2016
We would have segfaulted in the above code if prog could be NULL.
---
src/mesa/drivers/dri/i965/brw_gs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_gs.c b/src/mesa/drivers/dri/i965/brw_gs.c
index 4dddb86..8f5dcf3 100644
--- a/src/mesa/drivers/dri/i965/brw_gs.c
+++ b/src/mesa/drivers/dri/i965/brw_gs.c
@@ -144,7 +144,7 @@ brw_codegen_gs_prog(struct brw_context *brw,
brw_compute_vue_map(brw->intelScreen->devinfo,
&prog_data.base.vue_map, outputs_written,
- prog ? prog->SeparateShader : false);
+ prog->SeparateShader);
if (unlikely(INTEL_DEBUG & DEBUG_GS))
brw_dump_ir("geometry", prog, gs, NULL);
--
2.5.5
More information about the mesa-dev
mailing list