summaryrefslogtreecommitdiff
path: root/dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2025-04-02 00:42:52 -0400
committerIonen Wolkens <ionen@gentoo.org>2025-04-02 00:52:26 -0400
commit9fd435f3de4c68f9a3c762d4a30083c61befb077 (patch)
treeef20f60c5116e7b353ab0f5da7058ff5fa1cfbfb /dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch
parent4ae5cd64b815171488a94d040de6995440b5b876 (diff)
downloadgentoo-9fd435f3de4c68f9a3c762d4a30083c61befb077.tar.gz
gentoo-9fd435f3de4c68f9a3c762d4a30083c61befb077.tar.bz2
gentoo-9fd435f3de4c68f9a3c762d4a30083c61befb077.zip
dev-qt/qtwebengine: add 6.9.0
Also including backport for QTBUG-135047 (x11 pixmap leak) which is fixed in 6.9.9999 but hasn't been included in the 6.9.0 release. Not bothering putting it in the patchset given would need to make new one for 6.9.9999 already. The glibc-2.41 patch is also still not included, but it should whenever 6.9.9999 gets a qtwebengine-chromium submodule update. Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch')
-rw-r--r--dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch b/dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch
new file mode 100644
index 000000000000..17071b0c7354
--- /dev/null
+++ b/dev-qt/qtwebengine/files/qtwebengine-6.9.0-x11-pixmap-leak.patch
@@ -0,0 +1,43 @@
+Patch status: fixed in Qt 6.9.1
+
+https://bugreports.qt.io/browse/QTBUG-135047
+https://codereview.qt-project.org/c/qt/qtwebengine/+/634033
+--- a/src/core/compositor/native_skia_output_device_opengl.cpp
++++ b/src/core/compositor/native_skia_output_device_opengl.cpp
+@@ -214,9 +214,10 @@
+ glFun->glBindTexture(GL_TEXTURE_2D, 0);
+
+- m_frontBuffer->textureCleanupCallback = [glFun, glxFun, display, glxPixmap,
+- glTexture]() {
++ m_frontBuffer->textureCleanupCallback = [glFun, glxFun, display, glxPixmap, glTexture,
++ glxHelper, pixmapId]() {
+ glxFun->glXReleaseTexImageEXT(display, glxPixmap, GLX_FRONT_LEFT_EXT);
+ glFun->glDeleteTextures(1, &glTexture);
+ glXDestroyGLXPixmap(display, glxPixmap);
++ glxHelper->freePixmap(pixmapId);
+ };
+ }
+--- a/src/core/ozone/glx_helper.cpp
++++ b/src/core/ozone/glx_helper.cpp
+@@ -101,3 +101,13 @@
+ }
+
++void GLXHelper::freePixmap(uint32_t pixmapId) const
++{
++ xcb_void_cookie_t cookie = xcb_free_pixmap_checked(m_connection, pixmapId);
++ xcb_generic_error_t *error = xcb_request_check(m_connection, cookie);
++ if (error) {
++ qWarning("GLX: XCB_FREE_PIXMAP failed with error code: 0x%x", error->error_code);
++ free(error);
++ }
++}
++
+ QT_END_NAMESPACE
+--- a/src/core/ozone/glx_helper.h
++++ b/src/core/ozone/glx_helper.h
+@@ -34,4 +34,5 @@
+ GLXPixmap importBufferAsPixmap(int dmaBufFd, uint32_t size, uint16_t width, uint16_t height,
+ uint16_t stride) const;
++ void freePixmap(uint32_t pixmapId) const;
+ bool isDmaBufSupported() const { return m_isDmaBufSupported; }
+