From ef8d9fa7091b0d45fe15aae43b8f1c47547cb16d Mon Sep 17 00:00:00 2001 From: Rhys Weatherley Date: Fri, 9 Oct 2009 08:56:45 +1000 Subject: Prevent double-destroy of a pbuffer's EGLSurface Fixing the surface memory leak in b125af1b for widgets caused this knock-on effect in pbuffers. Reviewed-by: trustme --- src/opengl/qglpixelbuffer_egl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/opengl/qglpixelbuffer_egl.cpp b/src/opengl/qglpixelbuffer_egl.cpp index c2ba4a5..2b5e2f5 100644 --- a/src/opengl/qglpixelbuffer_egl.cpp +++ b/src/opengl/qglpixelbuffer_egl.cpp @@ -151,7 +151,7 @@ bool QGLPixelBufferPrivate::init(const QSize &size, const QGLFormat &f, QGLWidge bool QGLPixelBufferPrivate::cleanup() { - eglDestroySurface(QEglContext::defaultDisplay(0), pbuf); + // No need to destroy "pbuf" here - it is done in QGLContext::reset(). return true; } -- cgit v0.12