Bug 467430

Summary: Akonadi crash when cursor moves into a tooltip popup window
Product: [Frameworks and Libraries] Akonadi Reporter: David Tonhofer <bughunt>
Component: serverAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED DUPLICATE    
Severity: crash CC: bughunt, MacrosV, postix
Priority: NOR Keywords: drkonqi
Version: unspecified   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: New crash information added by DrKonqi
New crash information added by DrKonqi
core backtrace collected at kwin crash

Description David Tonhofer 2023-03-16 07:43:08 UTC
Application: akonadiserver (5.22.0 (22.12.0))

Qt Version: 5.15.8
Frameworks Version: 5.103.0
Operating System: Linux 6.1.18-100.fc36.x86_64 x86_64
Windowing System: Wayland
Distribution: Fedora Linux 36 (KDE Plasma)
DrKonqi: 5.27.1 [KCrashBackend]

-- Information about the crash:
I feel this is at least the 3 time I have encountered this crash

What happens:

- I have a large-ish list of ODT LibreOffice Text docucment, the directory where they reside is open in DOLPHIN 
- Iteratively do:
-- Click on document, opening it.
-- Edit the name of the document in DOLPHIN by prepending a date (YYYY_MM_DD_) found inside the document. Hit RETURN.
-- This rearranges the document list in DOLPHIN of course (as expected, but I know that renaming documents in DOLPHIN used to be fraught with some arbitrariness & danger)
-- Do not bother to close thise LibreOffice Writer instance, which accumulates windows, but that's ok as I can close them all in one click once done.

The crash seems to occur after hitting RETURN upon having renamed a document.

Also, YouTube is playing lofi in the background.

The reporter is unsure if this crash is reproducible.

-- Backtrace:
Application: Akonadi Server (akonadiserver), signal: Segmentation fault

[KCrash Handler]
#4  std::default_delete<Akonadi::Server::Connection>::operator() (__ptr=0x111, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:89
#5  std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >::~unique_ptr (this=<optimized out>, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:396
#6  std::__new_allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, this=0x7fff9bf42a28) at /usr/include/c++/12/bits/new_allocator.h:181
#7  std::allocator_traits<std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, __a=...) at /usr/include/c++/12/bits/alloc_traits.h:535
#8  std::vector<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >, std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::_M_erase (__position=..., this=0x7fff9bf42a28) at /usr/include/c++/12/bits/vector.tcc:181
#9  std::vector<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >, std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::erase (__position=..., this=0x7fff9bf42a28) at /usr/include/c++/12/bits/stl_vector.h:1530
#10 Akonadi::Server::AkonadiServer::connectionDisconnected (this=0x7fff9bf429a0) at /usr/src/debug/kf5-akonadi-server-22.12.0-2.fc36.x86_64/src/server/akonadi.cpp:234
#11 0x00007f0e8aec8134 in QObject::event(QEvent*) () from /lib64/libQt5Core.so.5
#12 0x00007f0e8ae9d4cb in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib64/libQt5Core.so.5
#13 0x00007f0e8aea0854 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /lib64/libQt5Core.so.5
#14 0x00007f0e8aeeeb07 in postEventSourceDispatch(_GSource*, int (*)(void*), void*) () from /lib64/libQt5Core.so.5
#15 0x00007f0e89b18faf in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#16 0x00007f0e89b6e2c8 in g_main_context_iterate.constprop () from /lib64/libglib-2.0.so.0
#17 0x00007f0e89b16940 in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#18 0x00007f0e8aeee5fa in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib64/libQt5Core.so.5
#19 0x00007f0e8ae9bf3a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib64/libQt5Core.so.5
#20 0x00007f0e8aea4002 in QCoreApplication::exec() () from /lib64/libQt5Core.so.5
#21 0x000055fcbd308058 in AkApplicationBase::exec (this=0x7fff9bf42970) at /usr/src/debug/kf5-akonadi-server-22.12.0-2.fc36.x86_64/src/shared/akapplication.cpp:107
#22 main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/kf5-akonadi-server-22.12.0-2.fc36.x86_64/src/server/main.cpp:65
[Inferior 1 (process 2555) detached]

Reported using DrKonqi
Comment 1 David Tonhofer 2023-03-22 20:18:20 UTC
Created attachment 157520 [details]
New crash information added by DrKonqi

akonadiserver (5.22.0 (22.12.0)) using Qt 5.15.8

I happened again.

The triggering event seems to be a yellow-colored tooltip that pops up near the mouse. If the mouse cursor is moved into the tooltip, akonadi crashes.

-- Backtrace (Reduced):
#4  std::default_delete<Akonadi::Server::Connection>::operator() (__ptr=0x111, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:89
#5  std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >::~unique_ptr (this=<optimized out>, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:396
#6  std::__new_allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, this=0x7fff5f24b0b8) at /usr/include/c++/12/bits/new_allocator.h:181
#7  std::allocator_traits<std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, __a=...) at /usr/include/c++/12/bits/alloc_traits.h:535
#8  std::vector<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >, std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::_M_erase (__position=..., this=0x7fff5f24b0b8) at /usr/include/c++/12/bits/vector.tcc:181
Comment 2 David Tonhofer 2023-03-22 20:25:51 UTC
VERY reproducible. But I'm not sure whether it is KDE/Qt, GTK or Fedora related.

For example, if you have the "abrt" tool open (report-gtk) and you activate the tooltip for the "minimize" button in the "abrt" window's decorations and you move the mouse into the tooltip ... kwin_wayland goes down with segmentation fault.
Comment 3 MacrosV@Gmail.com 2023-04-07 12:18:52 UTC
Created attachment 157923 [details]
New crash information added by DrKonqi

akonadiserver (5.22.3 (22.12.3)) using Qt 5.15.8

I find that I can very reliably induce this crash by simply leaving my system unattended for long enough to cause the screens to turn off. I did recently decide to temporarily disable system locking, so that may have something to do with it, but I cannot be entirely sure that this is related as I have noticed problems whether or not I have my screen locked, provided that I have had my screens turn off. Furthermore, if I do not restart my system and allow the crash to occur once more it results in all open programs being closed and I am forced to kill and relaunch plasmashell to get my desktop functional once more. Another odd thing I have noticed is that I no longer have any notification that I have experienced a crash and the KDE Crash Handler no longer registers that a crash has occurred after the first crash has taken place.

-- Backtrace (Reduced):
#4  std::default_delete<Akonadi::Server::Connection>::operator() (__ptr=0x110, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:89
#5  std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >::~unique_ptr (this=<optimized out>, this=<optimized out>) at /usr/include/c++/12/bits/unique_ptr.h:396
#6  std::__new_allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, this=0x7fff9a93a3d8) at /usr/include/c++/12/bits/new_allocator.h:181
#7  std::allocator_traits<std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::destroy<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > (__p=<optimized out>, __a=...) at /usr/include/c++/12/bits/alloc_traits.h:535
#8  std::vector<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> >, std::allocator<std::unique_ptr<Akonadi::Server::Connection, std::default_delete<Akonadi::Server::Connection> > > >::_M_erase (__position=..., this=0x7fff9a93a3d8) at /usr/include/c++/12/bits/vector.tcc:181
Comment 4 David Tonhofer 2023-04-07 14:59:42 UTC
While trying to reproduce via:

1) Start Godot
2) Make a "yellow tooltip" pop up about the window frame (not proper to Godot but to the window manager) for example, go into the "minimize" button until "minimize" pops up
3) Move the mouse into the "minimize" tooltip
4) Kwin (not only Akonadi) crashes with segmentation fault (but I can't report bug because "kernel is tainted", cat /proc/sys/kernel/tainted says "512", i.e. "kernel issued warning"). 

running: kwin-wayland-5.27.3-2.fc36

crash function:  QTimer::timeout(QTimer::QPrivateSignal)

Attaching the "core_backtrace", for what it's worth
Comment 5 David Tonhofer 2023-04-07 15:00:41 UTC
Created attachment 157928 [details]
core backtrace collected at kwin crash

This may only be remotely related to the reported bug
Comment 6 postix 2023-04-10 16:06:39 UTC

*** This bug has been marked as a duplicate of bug 450217 ***