aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorIgor Oliveira <[email protected]>2010-01-24 12:26:31 -0400
committerChia-I Wu <[email protected]>2010-01-25 10:30:51 +0800
commitdaea9270f877e3f32ef93f71ffa2d27dac4162b4 (patch)
tree3675793d4feb99bbb9dce03980348565198eef91 /src/gallium
parent9e1550dbafe1b28b81dc15822762e6cfe53e3a4b (diff)
egl: check if driver_name is null
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/state_trackers/egl/x11/native_x11.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/egl/x11/native_x11.c b/src/gallium/state_trackers/egl/x11/native_x11.c
index 695ab88010b..dd3c9f8b6ac 100644
--- a/src/gallium/state_trackers/egl/x11/native_x11.c
+++ b/src/gallium/state_trackers/egl/x11/native_x11.c
@@ -70,7 +70,8 @@ native_create_probe(EGLNativeDisplayType dpy)
if (xscr) {
if (x11_screen_support(xscr, X11_SCREEN_EXTENSION_DRI2)) {
driver_name = x11_screen_probe_dri2(xscr);
- nprobe->data = strdup(driver_name);
+ if (driver_name)
+ nprobe->data = strdup(driver_name);
}
x11_screen_destroy(xscr);