i965: check NULL pointer. fix bug#12193
authorXiang, Haihao <haihao.xiang@intel.com>
Wed, 29 Aug 2007 17:03:34 +0000 (13:03 -0400)
committerXiang, Haihao <haihao.xiang@intel.com>
Wed, 29 Aug 2007 17:03:34 +0000 (13:03 -0400)
src/mesa/drivers/dri/i965/intel_pixel_bitmap.c

index f3f062e6517a87dfbe5558b65a6a4d0a4db63c36..23f381fe9175b118d369a34bc3bcd82e20b7864a 100644 (file)
@@ -174,6 +174,8 @@ do_blit_bitmap( GLcontext *ctx,
       GLubyte ub[4];
    } color;
 
+   if (!dst)
+       return GL_FALSE;
 
    if (unpack->BufferObj->Name) {
       bitmap = map_pbo(ctx, width, height, unpack, bitmap);