From: Vinson Lee Date: Sun, 28 Feb 2010 00:28:30 +0000 (-0800) Subject: r128: Add assert to check for null pointer dereference. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a5406444aeeef40c899a4159a1fae6d1501bc1cb;p=mesa.git r128: Add assert to check for null pointer dereference. --- diff --git a/src/mesa/drivers/dri/r128/r128_texmem.c b/src/mesa/drivers/dri/r128/r128_texmem.c index 5eec8c08cd6..412f6d42551 100644 --- a/src/mesa/drivers/dri/r128/r128_texmem.c +++ b/src/mesa/drivers/dri/r128/r128_texmem.c @@ -260,6 +260,7 @@ void r128UploadTexImages( r128ContextPtr rmesa, r128TexObjPtr t ) } /* Set the base offset of the texture image */ + assert(t->base.memBlock); t->bufAddr = rmesa->r128Screen->texOffset[heap] + t->base.memBlock->ofs;