summaryrefslogtreecommitdiffstats
path: root/src/egl/main/egldriver.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/egl/main/egldriver.c')
-rw-r--r--src/egl/main/egldriver.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c
index 9d77cb6e97b..34a90ae5dc5 100644
--- a/src/egl/main/egldriver.c
+++ b/src/egl/main/egldriver.c
@@ -54,12 +54,8 @@ _eglGetDriver(void)
{
mtx_lock(&_eglModuleMutex);
- if (!_eglDriver) {
- _eglDriver = calloc(1, sizeof(*_eglDriver));
- if (!_eglDriver)
- return NULL;
- _eglInitDriver(_eglDriver);
- }
+ if (!_eglDriver)
+ _eglDriver = _eglBuiltInDriver();
mtx_unlock(&_eglModuleMutex);