check for winsys->destroy before calling
authorAlan Hourihane <alanh@tungstengraphics.com>
Thu, 14 Aug 2008 08:52:15 +0000 (09:52 +0100)
committerAlan Hourihane <alanh@tungstengraphics.com>
Thu, 14 Aug 2008 08:52:15 +0000 (09:52 +0100)
src/gallium/drivers/i915simple/i915_context.c

index e3d19017b5d6f9903de71543f2d2598d7dc0e349..e2bf5ab678fc07547ebfd30171179b4676a05289 100644 (file)
@@ -45,7 +45,7 @@ static void i915_destroy( struct pipe_context *pipe )
 
    draw_destroy( i915->draw );
    
-   if(i915->winsys)
+   if(i915->winsys->destroy)
       i915->winsys->destroy(i915->winsys);
 
    FREE( i915 );