radeonsi: fix a crash if ps_shader.cso is NULL in si_get_total_colormask

This commit is contained in:
Marek Olšák
2018-04-05 15:53:52 -04:00
parent be4250aa88
commit c7dd59b06d
+3
View File
@@ -1237,6 +1237,9 @@ static inline unsigned si_get_total_colormask(struct si_context *sctx)
return 0;
struct si_shader_selector *ps = sctx->ps_shader.cso;
if (!ps)
return 0;
unsigned colormask = sctx->framebuffer.colorbuf_enabled_4bit &
sctx->queued.named.blend->cb_target_mask;