Created attachment 117356 [details] Backtrace generated by the KCrash handler after the segfault SUMMARY When I open the address book, search for a record and try to delete it, Trojitá crashes. STEPS TO REPRODUCE 1. Open the address book. 2. Type something into the search box. 3. Delete a record from the result set. 4. Close the window. 5. Confirm saving the changes. OBSERVED RESULT Trojitá segfaults. After launching it again, the record was not deleted. EXPECTED RESULT The record is deleted and the software continues running. SOFTWARE/OS VERSIONS Linux/KDE Plasma: KDE Plasma Version: 5.14.3 KDE Frameworks Version: 5.52.0 Qt Version: 5.11.1 ADDITIONAL INFORMATION It may be related to https://bugs.kde.org/show_bug.cgi?id=384761 Backtrace after the crash is in the attachment.
Indeed, I can reproduce it here: Thread 1 "trojita" received signal SIGSEGV, Segmentation fault. 0x000055555568aec7 in AbookAddressbook::saveContacts() () at /home/jkt/work/prog/trojita/src/Plugins/AbookAddressbook/AbookAddressbook.cpp:312 312 if (it->first == Mail) (gdb) bt #0 0x000055555568aec7 in AbookAddressbook::saveContacts() () at /home/jkt/work/prog/trojita/src/Plugins/AbookAddressbook/AbookAddressbook.cpp:312 #1 0x00005555556933bb in BE::Contacts::saveContacts (this=0x555555fca580) at /home/jkt/work/prog/trojita/src/Plugins/AbookAddressbook/be-contacts.cpp:173 #2 BE::Contacts::closeEvent(QCloseEvent*) () at /home/jkt/work/prog/trojita/src/Plugins/AbookAddressbook/be-contacts.cpp:163 #3 0x00007ffff3334c48 in QWidget::event (this=0x555555fca580, event=0x7fffffffcd50) at /var/tmp/portage/dev-qt/qtwidgets-5.11.9999/work/qtwidgets-5.11.9999/src/widgets/kernel/qwidget.cpp:8916 Also, the list of matching items gets empty right after that deletion attempt even though there are some more matching items. That appears quite relevant. A first thing to be checked is proper QModelIndex invalidation, but I haven't checked the code. Patches welcome, of course.
Trojitá is no longer maintained, please switch to a maintained alternative like https://apps.kde.org/kmail2/ Sorry for the inconveniences.