diff options
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_gs_surface_state.c')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_gs_surface_state.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_gs_surface_state.c b/src/mesa/drivers/dri/i965/brw_gs_surface_state.c index dd43edfec85..f9cd18989f7 100644 --- a/src/mesa/drivers/dri/i965/brw_gs_surface_state.c +++ b/src/mesa/drivers/dri/i965/brw_gs_surface_state.c @@ -103,11 +103,12 @@ brw_upload_gs_abo_surfaces(struct brw_context *brw) /* _NEW_PROGRAM */ struct gl_shader_program *prog = ctx->_Shader->CurrentProgram[MESA_SHADER_GEOMETRY]; + const struct gl_program *gp = brw->geometry_program; - if (prog) { + if (gp && prog) { /* BRW_NEW_GS_PROG_DATA */ brw_upload_abo_surfaces(brw, prog->_LinkedShaders[MESA_SHADER_GEOMETRY], - &brw->gs.base, brw->gs.base.prog_data); + gp, &brw->gs.base, brw->gs.base.prog_data); } } |