Re: [PATCH] egl: refcount wl_egl_window objects. fix memory corruption

2013-10-22 Thread Kristian Høgsberg
On Mon, Oct 07, 2013 at 10:09:17PM +0200, Giulio Camuffo wrote: > Suppose we create a wl_egl_window and an EGLSurface. Then we call > eglMakeCurrent(dpy,surf,surf,ctx) with that surface, render and swap. > Later we destroy the surface and the window, and we make current > another surface. That resu

[PATCH] egl: refcount wl_egl_window objects. fix memory corruption

2013-10-07 Thread Giulio Camuffo
Suppose we create a wl_egl_window and an EGLSurface. Then we call eglMakeCurrent(dpy,surf,surf,ctx) with that surface, render and swap. Later we destroy the surface and the window, and we make current another surface. That resulted in two invalid writes because the surface, which is refcounted, get