summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/glx/xlib
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-06-17 08:33:39 -0600
committerBrian Paul <[email protected]>2009-06-17 08:38:38 -0600
commit3705f48688d7d2c8d4ff5f108ff6b56e289d1967 (patch)
treec43e5d92c8e473dd7d6ac9722f5983f179219df5 /src/gallium/state_trackers/glx/xlib
parentc6f71eabd877e14583725a29790872e96ff4dbb2 (diff)
st/glx: added null ptr check in Fake_glXCreatePixmap()
Fixes segfault in progs/xdemos/glxgears_pixmap.c
Diffstat (limited to 'src/gallium/state_trackers/glx/xlib')
-rw-r--r--src/gallium/state_trackers/glx/xlib/fakeglx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/glx/xlib/fakeglx.c b/src/gallium/state_trackers/glx/xlib/fakeglx.c
index 65e7048188e..6df4c7d6936 100644
--- a/src/gallium/state_trackers/glx/xlib/fakeglx.c
+++ b/src/gallium/state_trackers/glx/xlib/fakeglx.c
@@ -1817,7 +1817,7 @@ Fake_glXCreatePixmap( Display *dpy, GLXFBConfig config, Pixmap pixmap,
if (!dpy || !config || !pixmap)
return 0;
- for (attr = attribList; *attr; attr++) {
+ for (attr = attribList; attr && *attr; attr++) {
switch (*attr) {
case GLX_TEXTURE_FORMAT_EXT:
attr++;