From e63f532d26d82c06281840a84c73e2e36d7b3e1e Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Sat, 27 Feb 2010 02:18:06 -0800 Subject: [PATCH] dri: Assert pointer is not null before dereferencing. --- src/mesa/drivers/dri/common/dri_util.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index b80b608f4b9..a4fd002664b 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -189,6 +189,7 @@ static int driBindContext(__DRIcontext *pcp, ** initialize the drawable information if has not been done before. */ + assert(psp); if (!psp->dri2.enabled) { if (pdp && !pdp->pStamp) { DRM_SPINLOCK(&psp->pSAREA->drawable_lock, psp->drawLockID); -- 2.30.2