From: Andreas Sturmlechner Date: Wed, 1 May 2019 11:36:50 +0000 (+0200) Subject: kde-apps/akonadi-calendar: Fix korgac crash X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=452f0a5dabfd4578e6d21867f486aad51d11b15a;p=gentoo.git kde-apps/akonadi-calendar: Fix korgac crash KDE-Bug: https://bugs.kde.org/show_bug.cgi?id=406411 Bug: https://bugs.gentoo.org/683274 Package-Manager: Portage-2.3.66, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner --- diff --git a/kde-apps/akonadi-calendar/akonadi-calendar-18.12.3-r2.ebuild b/kde-apps/akonadi-calendar/akonadi-calendar-18.12.3-r2.ebuild new file mode 100644 index 000000000000..8dceb3cf01e0 --- /dev/null +++ b/kde-apps/akonadi-calendar/akonadi-calendar-18.12.3-r2.ebuild @@ -0,0 +1,48 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +KDE_TEST="true" +inherit kde5 + +DESCRIPTION="Library for akonadi calendar integration" +LICENSE="GPL-2+ LGPL-2.1+" +KEYWORDS="amd64 ~arm64 x86" +IUSE="" + +DEPEND=" + $(add_frameworks_dep kcodecs) + $(add_frameworks_dep kconfig) + $(add_frameworks_dep kconfigwidgets) + $(add_frameworks_dep kcoreaddons) + $(add_frameworks_dep kdbusaddons) + $(add_frameworks_dep ki18n) + $(add_frameworks_dep kiconthemes) + $(add_frameworks_dep kio) + $(add_frameworks_dep kitemmodels) + $(add_frameworks_dep kjobwidgets) + $(add_frameworks_dep kwidgetsaddons) + $(add_frameworks_dep kwallet) + $(add_frameworks_dep kxmlgui) + $(add_kdeapps_dep akonadi '' 18.12.3-r1) + $(add_kdeapps_dep akonadi-contacts) + $(add_kdeapps_dep akonadi-mime) + $(add_kdeapps_dep kcalcore) + $(add_kdeapps_dep kcalutils) + $(add_kdeapps_dep kcontacts) + $(add_kdeapps_dep kidentitymanagement) + $(add_kdeapps_dep kmailtransport) + $(add_kdeapps_dep kmime) + $(add_qt_dep qtdbus) + $(add_qt_dep qtgui) + $(add_qt_dep qtwidgets) +" +RDEPEND="${DEPEND} + !kde-apps/kdepim-l10n + ! +Date: Wed, 27 Mar 2019 14:45:25 +0100 +Subject: Fix crash due to using an attribute from a collection that went out + of scope + +Summary: Probably a consequence of the const/non-const changes (detaching?) + +Test Plan: +Untested, but based on a crash report by Allen, pointing to +ETMCalendar::alarms() calling BlockAlarmsAttribute::isAlarmTypeBlocked +on line 579. + +Reviewers: dvratil, winterz + +Reviewed By: dvratil + +Subscribers: kde-pim + +Tags: #kde_pim + +Differential Revision: https://phabricator.kde.org/D20079 +--- + src/etmcalendar.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/etmcalendar.cpp b/src/etmcalendar.cpp +index 295785d..75e131b 100644 +--- a/src/etmcalendar.cpp ++++ b/src/etmcalendar.cpp +@@ -549,11 +549,12 @@ KCalCore::Alarm::List ETMCalendar::alarms(const QDateTime &from, + while (i.hasNext()) { + const Akonadi::Item item = i.next().value(); + ++ Akonadi::Collection parentCollection; // must have same lifetime as blockedAttr + BlockAlarmsAttribute *blockedAttr = nullptr; + + if (excludeBlockedAlarms) { + // take the collection from m_collectionMap, because we need the up-to-date collection attrs +- Akonadi::Collection parentCollection = d->mCollectionMap.value(item.storageCollectionId()); ++ parentCollection = d->mCollectionMap.value(item.storageCollectionId()); + if (parentCollection.isValid() && parentCollection.hasAttribute()) { + blockedAttr = parentCollection.attribute(); + if (blockedAttr->isEverythingBlocked()) { +-- +cgit v1.1