From 4ea5223a95436b76a3f808732c565e9833f84551 Mon Sep 17 00:00:00 2001 From: Emil Velikov Date: Thu, 18 Jun 2015 20:22:54 +0100 Subject: egl/wayland: cleanup dri2_wl_create_surface error path MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Emil Velikov Reviewed-by: Marek Olšák --- src/egl/drivers/dri2/platform_wayland.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/egl/drivers/dri2') diff --git a/src/egl/drivers/dri2/platform_wayland.c b/src/egl/drivers/dri2/platform_wayland.c index 6f42d90ed96..1e127607cdd 100644 --- a/src/egl/drivers/dri2/platform_wayland.c +++ b/src/egl/drivers/dri2/platform_wayland.c @@ -168,13 +168,11 @@ dri2_wl_create_surface(_EGLDriver *drv, _EGLDisplay *disp, dri2_surf); if (dri2_surf->dri_drawable == NULL) { _eglError(EGL_BAD_ALLOC, "dri2->createNewDrawable"); - goto cleanup_dri_drawable; + goto cleanup_surf; } return &dri2_surf->base; - cleanup_dri_drawable: - dri2_dpy->core->destroyDrawable(dri2_surf->dri_drawable); cleanup_surf: free(dri2_surf); -- cgit v1.2.3