Skip to content
Commit bab79bac authored by Volker Krause's avatar Volker Krause
Browse files

Don't attempt to clean up when the process is about to exit

Summary:
Fixes a heap-use-after-free ASAN error when the ETMCalendar singleton is
destroyed on shutdown.

==14556==ERROR: AddressSanitizer: heap-use-after-free on address 0x603000139910 at pc 0x7fe6291391e3 bp 0x7fff0d420ec0 sp 0x7fff0d420eb8
READ of size 8 at 0x603000139910 thread T0
#0 0x7fe6291391e2 in Akonadi::ChangeNotificationDependenciesFactory::destroyNotificationConnection(Akonadi::Session*, Akonadi::Connection*) /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/changenotificationdependenciesfactory.cpp:51
#1 0x7fe629301fcf in Akonadi::MonitorPrivate::disconnectFromNotificationManager() /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/monitor_p.cpp:120
#2 0x7fe6293008f2 in Akonadi::MonitorPrivate::~MonitorPrivate() /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/monitor_p.cpp:66
#3 0x7fe629300ef9 in Akonadi::MonitorPrivate::~MonitorPrivate() /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/monitor_p.cpp:71
#4 0x7fe6292d5c91 in Akonadi::Monitor::~Monitor() /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/monitor.cpp:61
#5 0x7fe6292d5cef in Akonadi::Monitor::~Monitor() /home/jenkins/workspace/Applications akonadi kf5-qt5 SUSEQt5.9/src/core/monitor.cpp:62
#6 0x7fe61eebe29a in QObjectPrivate::deleteChildren() (/usr/lib64/libQt5Core.so.5+0x29b29a)
#7 0x7fe61eec6de3 in QObject::~QObject() (/usr/lib64/libQt5Core.so.5+0x2a3de3)
#8 0x7fe5dd5b5a33 in KCalCore::Calendar::~Calendar() /home/jenkins/workspace/Dependency Build Applications kf5-qt5 SUSEQt5.9/kcalcore/src/calendar.cpp:154
#9 0x7fe5dd752127 in KCalCore::MemoryCalendar::~MemoryCalendar() /home/jenkins/workspace/Dependency Build Applications kf5-qt5 SUSEQt5.9/kcalcore/src/memorycalendar.cpp:144
#10 0x7fe5de22bf7c in Akonadi::CalendarBase::~CalendarBase() /home/jenkins/workspace/Dependency Build Applications kf5-qt5 SUSEQt5.9/akonadi-calendar/src/calendarbase.cpp:427
#11 0x7fe5de28d1cc in Akonadi::ETMCalendar::~ETMCalendar() /home/jenkins/workspace/Dependency Build Applications kf5-qt5 SUSEQt5.9/akonadi-calendar/src/etmcalendar.cpp:505
#12 0x7fe5de28d21d in Akonadi::ETMCalendar::~ETMCalendar() /home/jenkins/workspace/Dependency Build Applications kf5-qt5 SUSEQt5.9/akonadi-calendar/src/etmcalendar.cpp:507
#13 0x7fe5dfb473b7 in QtSharedPointer::CustomDeleter<Akonadi::ETMCalendar, QtSharedPointer::NormalDeleter>::execute() (/home/jenkins/install-prefix/lib64/libKF5CalendarSupport.so.5+0x2b93b7)
#14 0x7fe5dfb46bdb in QtSharedPointer::ExternalRefCountWithCustomDeleter<Akonadi::ETMCalendar, QtSharedPointer::NormalDeleter>::deleter(QtSharedPointer::ExternalRefCountData*) /usr/include/qt5/QtCore/qsharedpointer_impl.h:213
#15 0x7fe5dfb2c9f7 in QtSharedPointer::ExternalRefCountData::destroy() /usr/include/qt5/QtCore/qsharedpointer_impl.h:157
#16 0x7fe5dfb2f963 in QSharedPointer<Akonadi::ETMCalendar>::deref(QtSharedPointer::ExternalRefCountData*) /usr/include/qt5/QtCore/qsharedpointer_impl.h:461
#17 0x7fe5dfb2f498 in QSharedPointer<Akonadi::ETMCalendar>::deref() /usr/include/qt5/QtCore/qsharedpointer_impl.h:456
#18 0x7fe5dfb2d9dd in QSharedPointer<Akonadi::ETMCalendar>::~QSharedPointer() /usr/include/qt5/QtCore/qsharedpointer_impl.h:313
#19 0x7fe61df697cb in __run_exit_handlers (/lib64/libc.so.6+0x3a7cb)

Reviewers: dvratil

Reviewed By: dvratil

Subscribers: dvratil, kde-pim

Tags: #kde_pim

Differential Revision: https://phabricator.kde.org/D14263
parent 2026f71d
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment