egl/dri2: move surface refcounting out of the platform code
[mesa.git] / src / egl / drivers / dri2 / platform_drm.c
index 47add1250609cbaf395fa697c9d791da4afc06c8..2668dff66ca162e21b687d4b810d02181d73fe26 100644 (file)
@@ -191,9 +191,6 @@ dri2_drm_destroy_surface(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf)
    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++) {