summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/draw
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/auxiliary/draw')
-rw-r--r--src/gallium/auxiliary/draw/draw_gs.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/draw/draw_gs.c b/src/gallium/auxiliary/draw/draw_gs.c
index f8cb04a8f39..987c01a7919 100644
--- a/src/gallium/auxiliary/draw/draw_gs.c
+++ b/src/gallium/auxiliary/draw/draw_gs.c
@@ -788,6 +788,9 @@ void draw_bind_geometry_shader(struct draw_context *draw,
void draw_delete_geometry_shader(struct draw_context *draw,
struct draw_geometry_shader *dgs)
{
+ if (!dgs) {
+ return;
+ }
#ifdef HAVE_LLVM
if (draw_get_option_use_llvm()) {
struct llvm_geometry_shader *shader = llvm_geometry_shader(dgs);