revert upstream commit causing kopete crashes for now (kde#355275)
This commit is contained in:
parent
a8602f5ad2
commit
b370918161
51
Use-deleteLater-in-Part-slotWidgetDestroyed.patch
Normal file
51
Use-deleteLater-in-Part-slotWidgetDestroyed.patch
Normal file
@ -0,0 +1,51 @@
|
||||
commit 4f7ea2f770cf062ef22293fbb21a086f3e0cbfcb
|
||||
Author: Allen Winter <winter@kde.org>
|
||||
Date: Tue Oct 20 16:36:32 2015 -0400
|
||||
|
||||
backport commit b72fc5e56579035bf987075e16324ef95ef8e3d4
|
||||
Author: Alex Merry <alex.merry@kde.org>
|
||||
Date: Mon Oct 19 20:54:13 2015 +0100
|
||||
|
||||
Use deleteLater in Part::slotWidgetDestroyed().
|
||||
|
||||
When a part's main widget is destroyed, we should not delete the part
|
||||
immediately - both because deleting an object from inside one of its
|
||||
signals is not safe generally, and because derived classes may well hold
|
||||
QPointers to the widgets, expecting them to be cleared between the
|
||||
widget being destroyed and the part being destroyed.
|
||||
|
||||
MERGE: none
|
||||
|
||||
diff --git a/kparts/part.cpp b/kparts/part.cpp
|
||||
index 20089d4..2cfee81 100644
|
||||
--- a/kparts/part.cpp
|
||||
+++ b/kparts/part.cpp
|
||||
@@ -350,7 +350,7 @@ void Part::slotWidgetDestroyed()
|
||||
d->m_widget = 0;
|
||||
if (d->m_autoDeletePart) {
|
||||
kDebug(1000) << "deleting part" << objectName();
|
||||
- delete this; // ouch, this should probably be deleteLater()
|
||||
+ this->deleteLater();
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/kparts/tests/parttest.cpp b/kparts/tests/parttest.cpp
|
||||
index e48b578..232aa07 100644
|
||||
--- a/kparts/tests/parttest.cpp
|
||||
+++ b/kparts/tests/parttest.cpp
|
||||
@@ -48,6 +48,7 @@ void PartTest::testAutoDeletePart()
|
||||
KParts::Part* part = new TestPart(0, 0);
|
||||
QPointer<KParts::Part> partPointer(part);
|
||||
delete part->widget();
|
||||
+ QCoreApplication::sendPostedEvents(0, QEvent::DeferredDelete);
|
||||
QVERIFY(partPointer.isNull());
|
||||
}
|
||||
|
||||
@@ -57,6 +58,7 @@ void PartTest::testAutoDeleteWidget()
|
||||
QPointer<KParts::Part> partPointer(part);
|
||||
QPointer<QWidget> widgetPointer(part->widget());
|
||||
delete part;
|
||||
+ QCoreApplication::sendPostedEvents(0, QEvent::DeferredDelete);
|
||||
QVERIFY(widgetPointer.isNull());
|
||||
}
|
||||
|
@ -52,7 +52,7 @@ Summary: KDE Libraries
|
||||
# shipped with kde applications, version...
|
||||
%global apps_version 15.08.3
|
||||
Version: 4.14.14
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
|
||||
Name: kdelibs
|
||||
Epoch: 6
|
||||
@ -206,6 +206,9 @@ Patch093: turn-the-packagekit-support-feature-off-by-default.patch
|
||||
# plasma5 places syncing problems
|
||||
Patch094: 0015-Remove-bookmarks-syncing-from-KFilePlacesModel-and-u.patch
|
||||
|
||||
# kdelibs kparts fix that causes regressions in kopete, kde#355275
|
||||
Patch095: Use-deleteLater-in-Part-slotWidgetDestroyed.patch
|
||||
|
||||
## security fix
|
||||
|
||||
# rhel patches
|
||||
@ -478,6 +481,7 @@ sed -i -e "s|@@VERSION_RELEASE@@|%{version}-%{release}|" kio/kio/kprotocolmanage
|
||||
%if 0%{?fedora} < 22
|
||||
%patch094 -p1 -R -b .0015
|
||||
%endif
|
||||
%patch095 -p1 -R -b .Use-deleteLater-in-Part-slotWidgetDestroyed
|
||||
|
||||
# security fixes
|
||||
|
||||
@ -834,6 +838,9 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
|
||||
|
||||
%changelog
|
||||
* Sat Dec 05 2015 Rex Dieter <rdieter@fedoraproject.org> 6:4.14.14-3
|
||||
- revert upstream commit causing kopete crashes for now (kde#355275)
|
||||
|
||||
* Wed Nov 25 2015 Rex Dieter <rdieter@fedoraproject.org> 6:4.14.14-2
|
||||
- pull in upstream fixes
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user