From 76610d9fb0ba5a2d495a963773c38b717d76776f Mon Sep 17 00:00:00 2001 From: vaxerski Date: Sat, 27 Jul 2024 13:03:43 +0200 Subject: [PATCH] opengl: destroy cairo image surface after use --- src/render/OpenGL.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/render/OpenGL.cpp b/src/render/OpenGL.cpp index 5e52403d..39f6614e 100644 --- a/src/render/OpenGL.cpp +++ b/src/render/OpenGL.cpp @@ -2610,6 +2610,8 @@ void CHyprOpenGLImpl::createBackgroundTexture(const std::string& texPath) { } #endif glTexImage2D(GL_TEXTURE_2D, 0, glIFormat, m_pBackgroundTexture->m_vSize.x, m_pBackgroundTexture->m_vSize.y, 0, glFormat, glType, DATA); + + cairo_surface_destroy(CAIROSURFACE); } void CHyprOpenGLImpl::createBGTextureForMonitor(CMonitor* pMonitor) {