[SCM] KDE Base Workspace module packaging branch, master, updated. debian/4.10.5-2-4-g235d1ca
Pino Toscano
pino at alioth.debian.org
Mon Jul 22 10:04:48 UTC 2013
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-sc/kde-workspace.git;a=commitdiff;h=235d1ca
The following commit has been merged in the master branch:
commit 235d1caa1f09bd85c8c230e59e1b4b40e2904d74
Author: Pino Toscano <pino at debian.org>
Date: Mon Jul 22 12:04:30 2013 +0200
fix CVE-2013-4133
backport upstream commit 2c810db3e41d56ad7dd8ec3436f3cf3abcc31983
---
debian/changelog | 3 +
debian/patches/series | 1 +
...leak-when-the-tray-icon-changes-e.g.-when.patch | 60 ++++++++++++++++++++
3 files changed, 64 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 12adbb4..bd5f8ad 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,9 @@ kde-workspace (4:4.10.5-3) UNRELEASED; urgency=low
NULL pointer dereference in kcheckpass and kdm, CVE-2013-4132; patch
upstream_kdm-kcheckpass-Check-for-NULL-return-from-crypt-3-an.patch.
(Closes: #717180)
+ * Backport upstream commit 2c810db3e41d56ad7dd8ec3436f3cf3abcc31983 to fix
+ pixmap leaks in the system tray Plasma widget, CVE-2013-4133; patch
+ upstream_Fix-pixmap-leak-when-the-tray-icon-changes-e.g.-when.patch.
-- Debian Qt/KDE Maintainers <debian-qt-kde at lists.debian.org> Sun, 21 Jul 2013 15:20:50 +0200
diff --git a/debian/patches/series b/debian/patches/series
index ced992b..13087ec 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,5 @@
upstream_kdm-kcheckpass-Check-for-NULL-return-from-crypt-3-an.patch
+upstream_Fix-pixmap-leak-when-the-tray-icon-changes-e.g.-when.patch
kdm_does_not_wreak_havoc.diff
kdmrc_defaults.diff
genkdmconf.diff
diff --git a/debian/patches/upstream_Fix-pixmap-leak-when-the-tray-icon-changes-e.g.-when.patch b/debian/patches/upstream_Fix-pixmap-leak-when-the-tray-icon-changes-e.g.-when.patch
new file mode 100644
index 0000000..926c138
--- /dev/null
+++ b/debian/patches/upstream_Fix-pixmap-leak-when-the-tray-icon-changes-e.g.-when.patch
@@ -0,0 +1,60 @@
+From 2c810db3e41d56ad7dd8ec3436f3cf3abcc31983 Mon Sep 17 00:00:00 2001
+From: Andreas Hartmetz <ahartmetz at gmail.com>
+Date: Tue, 2 Jul 2013 18:35:35 +0200
+Subject: [PATCH] Fix pixmap leak when the tray icon changes (e.g. when it's
+ animated).
+
+This could easily leak 4KB/second of X pixmap memory.
+All the actual difference comes from the QPixmap::ExplicitlyShared
+argument, the rest is making some wonky-looking but working code look
+less wonky.
+
+BUG: 314919
+(cherry picked from commit ec8e405ca447ba5bc5a9f6a2a12e2fa90412a0d4)
+---
+ .../systemtray/protocols/fdo/x11embedcontainer.cpp | 19 ++++++++++---------
+ 1 file changed, 10 insertions(+), 9 deletions(-)
+
+diff --git a/plasma/generic/applets/systemtray/protocols/fdo/x11embedcontainer.cpp b/plasma/generic/applets/systemtray/protocols/fdo/x11embedcontainer.cpp
+index 1826512..a5bc826 100644
+--- a/plasma/generic/applets/systemtray/protocols/fdo/x11embedcontainer.cpp
++++ b/plasma/generic/applets/systemtray/protocols/fdo/x11embedcontainer.cpp
+@@ -194,8 +194,7 @@ void X11EmbedContainer::paintEvent(QPaintEvent *event)
+
+ // Taking a detour via a QPixmap is unfortunately the only way we can get
+ // the window contents into Qt's backing store.
+- QPixmap pixmap(size());
+- pixmap = toX11Pixmap(pixmap);
++ QPixmap pixmap = toX11Pixmap(QPixmap(size()));
+ pixmap.fill(Qt::transparent);
+ XRenderComposite(x11Info().display(), PictOpSrc, d->picture, None, pixmap.x11PictureHandle(),
+ 0, 0, 0, 0, 0, 0, width(), height());
+@@ -232,16 +231,18 @@ void X11EmbedContainer::setBackgroundPixmap(QPixmap background)
+ // NOTE: The alpha-channel is not preserved if it exists, but for X pixmaps it generally should not be needed anyway.
+ QPixmap X11EmbedContainer::toX11Pixmap(const QPixmap& pix)
+ {
+- if(pix.handle() != 0) // X11 pixmap
++ if (pix.handle() != 0) // X11 pixmap
+ return pix;
++ QPixmap ret;
+ Pixmap xpix = XCreatePixmap(pix.x11Info().display(), RootWindow(pix.x11Info().display(), pix.x11Info().screen()),
+ pix.width(), pix.height(), QX11Info::appDepth());
+- QPixmap wrk = QPixmap::fromX11Pixmap(xpix);
+- QPainter paint(&wrk);
+- paint.drawPixmap(0, 0, pix);
+- paint.end();
+- QPixmap ret = wrk.copy();
+- wrk = QPixmap(); // reset, so that xpix can be freed (QPixmap does not own it)
++ {
++ QPixmap wrk = QPixmap::fromX11Pixmap(xpix, QPixmap::ExplicitlyShared);
++ QPainter paint(&wrk);
++ paint.drawPixmap(0, 0, pix);
++ paint.end();
++ ret = wrk.copy();
++ } // free resources so that xpix can be freed (QPixmap does not own it)
+ XFreePixmap(pix.x11Info().display(), xpix);
+ return ret;
+ }
+--
+1.7.10.4
+
--
KDE Base Workspace module packaging
More information about the pkg-kde-commits
mailing list