dri2_destroy_surface(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSurface *surf)
{
struct dri2_egl_display *dri2_dpy = dri2_egl_display(dpy);
+
+ if (!_eglPutSurface(surf))
+ return EGL_TRUE;
+
return dri2_dpy->vtbl->destroy_surface(drv, dpy, surf);
}
struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp);
struct dri2_egl_surface *dri2_surf = dri2_egl_surface(surf);
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
droid_free_local_buffers(dri2_surf);
if (dri2_surf->base.Type == EGL_WINDOW_BIT) {
struct dri2_egl_surface *dri2_surf = dri2_egl_surface(surf);
unsigned i;
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
(*dri2_dpy->core->destroyDrawable)(dri2_surf->dri_drawable);
for (i = 0; i < ARRAY_SIZE(dri2_surf->color_buffers); i++) {
struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp);
struct dri2_egl_surface *dri2_surf = dri2_egl_surface(surf);
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
surfaceless_free_images(dri2_surf);
(*dri2_dpy->core->destroyDrawable)(dri2_surf->dri_drawable);
(void) drv;
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
(*dri2_dpy->core->destroyDrawable)(dri2_surf->dri_drawable);
for (i = 0; i < ARRAY_SIZE(dri2_surf->color_buffers); i++) {
(void) drv;
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
(*dri2_dpy->core->destroyDrawable)(dri2_surf->dri_drawable);
if (dri2_dpy->dri2) {
(void) drv;
- if (!_eglPutSurface(surf))
- return EGL_TRUE;
-
loader_dri3_drawable_fini(&dri3_surf->loader_drawable);
free(surf);