From: Kristian Høgsberg Date: Thu, 27 May 2010 01:33:18 +0000 (-0400) Subject: egl: Return NULL if we fail to load a default driver X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6e9da8ab6085b72473aa414922aa9cfa6ee508f9;p=mesa.git egl: Return NULL if we fail to load a default driver --- diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c index 566554d51dc..2f42e64fbe0 100644 --- a/src/egl/main/egldriver.c +++ b/src/egl/main/egldriver.c @@ -571,7 +571,7 @@ _eglLoadDefaultDriver(EGLDisplay dpy, EGLint *major, EGLint *minor) _eglUnlockMutex(_eglGlobal.Mutex); - return drv; + return _eglGlobal.NumDrivers > 0 ? drv : NULL; }