Merge lp:~sil2100/kubuntu-packaging/qtbase-opensource-src_5.0.2_qapp_fix into lp:~kubuntu-packagers/kubuntu-packaging/qtbase-opensource-src_5.0.2

Proposed by Łukasz Zemczak
Status: Merged
Merge reported by: Timo Jyrinki
Merged at revision: not available
Proposed branch: lp:~sil2100/kubuntu-packaging/qtbase-opensource-src_5.0.2_qapp_fix
Merge into: lp:~kubuntu-packagers/kubuntu-packaging/qtbase-opensource-src_5.0.2
Diff against target: 26 lines (+14/-0)
2 files modified
debian/patches/fix_destroy_qapp_segfault.diff (+13/-0)
debian/patches/series (+1/-0)
To merge this branch: bzr merge lp:~sil2100/kubuntu-packaging/qtbase-opensource-src_5.0.2_qapp_fix
Reviewer Review Type Date Requested Status
Timo Jyrinki Approve
Review via email: mp+204471@code.launchpad.net

Commit message

Fix a segmentation fault bug in a strange case when a QWidget element (for instance, a QMenu element) gets freed (destroyed) after the main application exits and QApplication objects stops existing. Do not assume qApp will be present when cleaning memory. Fixes #1273306.

Description of the change

Fix a segmentation fault bug in a strange case when a QWidget element (for instance, a QMenu element) gets freed (destroyed) after the main application exits and QApplication objects stops existing. Do not assume qApp will be present when cleaning memory.

To post a comment you must log in.
Revision history for this message
Dmitry Shachnev (mitya57) wrote :

Is this fixed in 5.2? Or at least submitted upstream?

Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

Yes, please find out the upstream situation and whether the patch needs to be proposed against trunk and backported to 5.2.0 as well.

review: Needs Fixing
Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

Ok, it's in upstream trunk and also Qt 5.2 already, it's just that Łukasz found about the fix on his own.

review: Approve
Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'debian/patches/fix_destroy_qapp_segfault.diff'
2--- debian/patches/fix_destroy_qapp_segfault.diff 1970-01-01 00:00:00 +0000
3+++ debian/patches/fix_destroy_qapp_segfault.diff 2014-02-03 12:26:23 +0000
4@@ -0,0 +1,13 @@
5+Index: qtbase-opensource-src-5.0.2+dfsg1/src/widgets/kernel/qwidget_qpa.cpp
6+===================================================================
7+--- qtbase-opensource-src-5.0.2+dfsg1.orig/src/widgets/kernel/qwidget_qpa.cpp 2013-04-09 01:11:06.000000000 +0100
8++++ qtbase-opensource-src-5.0.2+dfsg1/src/widgets/kernel/qwidget_qpa.cpp 2014-02-03 10:33:52.123196922 +0000
9+@@ -168,7 +168,7 @@
10+ parentWidget()->d_func()->invalidateBuffer(d->effectiveRectFor(geometry()));
11+ d->deactivateWidgetCleanup();
12+
13+- if ((windowType() == Qt::Popup))
14++ if ((windowType() == Qt::Popup) && qApp)
15+ qApp->d_func()->closePopup(this);
16+
17+ if (this == QApplicationPrivate::active_window)
18
19=== modified file 'debian/patches/series'
20--- debian/patches/series 2014-01-13 09:30:41 +0000
21+++ debian/patches/series 2014-02-03 12:26:23 +0000
22@@ -21,3 +21,4 @@
23 aarch64_fix_atomic_set.patch
24 Add-workaround-for-GL-on-Android-emulator.patch
25 CVE-2013-4549-xml-expansion.diff
26+fix_destroy_qapp_segfault.diff

Subscribers

People subscribed via source and target branches