summaryrefslogtreecommitdiffstats
path: root/src/egl/drivers/dri
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2008-06-04 11:50:18 -0600
committerBrian Paul <[email protected]>2008-06-05 12:01:33 -0600
commitf6bb2f87b96bd05661020cf8e73e80f5ef25353a (patch)
treea26dac95efd3d09ee138bd7a035e2e9e893581f8 /src/egl/drivers/dri
parentda7b3d294b2827f26bdb6dcbe7c123e77865c160 (diff)
egl: minor tweaks
Diffstat (limited to 'src/egl/drivers/dri')
-rw-r--r--src/egl/drivers/dri/egldri.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/egl/drivers/dri/egldri.c b/src/egl/drivers/dri/egldri.c
index 1a922a74717..57661cc3ab8 100644
--- a/src/egl/drivers/dri/egldri.c
+++ b/src/egl/drivers/dri/egldri.c
@@ -82,7 +82,7 @@ _EGLDriver *
_eglMain(_EGLDisplay *dpy, const char *args)
{
#if 1
- const int card = atoi(args);
+ const int card = args ? atoi(args) : 0;
_EGLDriver *driver = NULL;
char driverName[1000];
@@ -1086,8 +1086,10 @@ _eglDRICreateDisplay(driDisplay *dpy, __DRIframebuffer *framebuffer)
api_ver,
& interface_methods,
NULL);
- if (!dpy->driScreen.private)
+ if (!dpy->driScreen.private) {
+ _eglLog(_EGL_WARNING, "egldri.c: DRI create new screen failed");
return EGL_FALSE;
+ }
DRM_UNLOCK( dpy->drmFD, dpy->pSAREA, dpy->serverContext );