projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1b8c9fe
)
dri: Make it a little clearer that we're not dereferencing a NULL pointer
author
nobled
<nobled@dreamwidth.org>
Tue, 7 Sep 2010 16:26:07 +0000
(12:26 -0400)
committer
Kristian Høgsberg
<krh@bitplanet.net>
Tue, 7 Sep 2010 16:26:33 +0000
(12:26 -0400)
src/mesa/drivers/dri/common/dri_util.c
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/common/dri_util.c
b/src/mesa/drivers/dri/common/dri_util.c
index 5f07986773968a22c9e0019a32953e9bddbf12c9..f07c3da4bb62649708bd3b1adebf8456aeacdd18 100644
(file)
--- a/
src/mesa/drivers/dri/common/dri_util.c
+++ b/
src/mesa/drivers/dri/common/dri_util.c
@@
-635,6
+635,7
@@
dri2CreateNewContextForAPI(__DRIscreen *screen, int api,
__DRIcontext *shared, void *data)
{
__DRIcontext *context;
+ const __GLcontextModes *modes = (config != NULL) ? &config->modes : NULL;
void *shareCtx = (shared != NULL) ? shared->driverPrivate : NULL;
gl_api mesa_api;
@@
-663,7
+664,7
@@
dri2CreateNewContextForAPI(__DRIscreen *screen, int api,
context->driDrawablePriv = NULL;
context->loaderPrivate = data;
- if (!(*screen->DriverAPI.CreateContext)(mesa_api,
&config->
modes,
+ if (!(*screen->DriverAPI.CreateContext)(mesa_api, modes,
context, shareCtx) ) {
free(context);
return NULL;