diff options
author | Alan Hourihane <alanh@tungstengraphics.com> | 2008-06-09 16:24:15 +0100 |
---|---|---|
committer | Alan Hourihane <alanh@tungstengraphics.com> | 2008-06-09 16:25:01 +0100 |
commit | 5cf69fe511a67a7bcf6787974becf6a143abb507 (patch) | |
tree | b05312e8c84181ec54ad05d99f106f0a79ab2a70 | |
parent | 906e189bd362399f1ffc4d5421ae0d0abd586977 (diff) |
Check for NULL pointer
-rw-r--r-- | src/mesa/drivers/dri/common/dri_util.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 6efdf4312a..e2beae380e 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -602,6 +602,8 @@ dri2CreateNewDrawable(__DRIscreen *screen, const __DRIconfig *config, __DRIdrawable *pdraw; pdraw = driCreateNewDrawable(screen, config, 0, 0, NULL, data); + if (!pdraw) + return NULL; pdraw->dri2.drawable_id = drawable_id; pdraw->dri2.tail = head; |