summaryrefslogtreecommitdiff
path: root/src/egl/drivers/dri2/egl_dri2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/egl/drivers/dri2/egl_dri2.c')
-rw-r--r--src/egl/drivers/dri2/egl_dri2.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c
index 44c9bc18d6..4c9ece351a 100644
--- a/src/egl/drivers/dri2/egl_dri2.c
+++ b/src/egl/drivers/dri2/egl_dri2.c
@@ -608,6 +608,8 @@ dri2_terminate(_EGLDriver *drv, _EGLDisplay *disp)
close(dri2_dpy->fd);
if (dri2_dpy->driver)
dlclose(dri2_dpy->driver);
+ if (dri2_dpy->device_name)
+ free(dri2_dpy->device_name);
if (disp->PlatformDisplay == NULL) {
switch (disp->Platform) {
@@ -616,14 +618,9 @@ dri2_terminate(_EGLDriver *drv, _EGLDisplay *disp)
xcb_disconnect(dri2_dpy->conn);
break;
#endif
-#ifdef HAVE_WAYLAND_PLATFORM
- case _EGL_PLATFORM_WAYLAND:
- wl_display_destroy(dri2_dpy->wl_dpy);
- break;
-#endif
#ifdef HAVE_DRM_PLATFORM
case _EGL_PLATFORM_DRM:
- if (dri2_dpy->own_gbm_device) {
+ if (dri2_dpy->own_device) {
gbm_device_destroy(&dri2_dpy->gbm_dri->base.base);
}
break;