Since the recent updates of Qt, KDE Frameworks and KDE Plasma, stable kmail crashes if one closes a message opened in a separate window. (One can do this by double-clicking a message.)
See also: https://marc.info/?t=155893811800005&r=1&w=2
added upstream report
I'm experimenting the very same problem, again in ~WebContentsAdapter() destructor, SEGFAULT, verified with gdb, qtwebengine-5.12.3, kmail-18.12.3-r1, stable Gentoo.
In the source qtwebengine-everywhere-src-5.12.3/src/core/web_contents_adapter.cpp there is one and only one ~WebContentsAdapter() destructor, at line 1677:
The source is quite different from previous version 5.11.3:
although the logic seems quite the same.
I can't see any backtrace call, with gdb, to the closeDevToolsFrontend() method, but the library doesn't contain any debug info, at the moment.
Do you think emerging qtwebengine-5.12.3 with USE=debug may help debugging this problem?
If the method closeDevToolsFrontend() was actually never called, it looks the SEGFAULT may arise because m_devToolsFrontend is not a null pointer, but it is not actually pointing to a valid memory area.
Maybe the Q_D() preprocessor macro, in the previous version, added some logic preventing the SEGFAULT?
I've a couple of systems which I actually need to update, where I use kmail for my daily duty.
In the meanwhile the problem is analyzed and solved, may I mask qt-5.12 with
and go on with my emerge to the last stable version, keeping kmail running with qt-5.11.3-r2?
I tested this configuration on one of my systems and it would emerge/update world, apparently.
Created attachment 577976 [details]
kmail gdb trace
Now I've a more meaningful gdb trace (with kmail and qtwebengine symbols) of the kmail SEGFAULT, I hope it may help to debug the problem.
The fault seems to begin its road at
Created attachment 578010 [details, diff]
It looks the problem is neither in kmail, neither in qtwebengine-5.12.3, apologies for my previous comments.
The smoking gun seems to be kde-apps/messagelib-18.12.3-r1, in its interface to qtwebengine-5.12.3, which is changed.
Reading this thread:
I realized that the problem is probably solved in the unstable kde-apps 19.04.1 (to which kmail belongs).
Anyway, from the "phabricator" thread, from its raw diff patch, with a minor change to the copyright date, I had been able to write down the attached user patch "msglib.patch" for the stable kde-apps/messagelib-18.12.3-r1 version.
With this user patch applied, kmail doesn't segfault anymore, closing a message window or even the main window (which share the same problem).
Not sure about what to do.
Waiting for 19.04.1 to become stable?
Installing the unstable version to my stable Gentoo?
Using this patch?
Thanks for identifying the fix! Meanwhile I also found a system to successfully reproduce the problem.
Clean backport of https://phabricator.kde.org/D19559 (no changes required) fixes the issue for me.
Thank you so much for your efforts Andreas, appreciated.
kmail, especially if used with "kontact", it is really a wonderful tool, a little bit complex actually. I can't find anything else matching the features of the kontact office suite elsewhere, at least under Gentoo Linux.
The only problem is in its complexity: there are layers and layers of packages between the application interface and the operating system.
I would really appreciate, as I use the suite for my daily duty, if the Gentoo team shall be a little bit more cautios about stabilization, in the future.
Being without a working mail interface for days, waiting for a fix, may be a BIG trouble for a real kmail user, like me.
And, under Gentoo, a monthly emerge can't be postponed for weeks ;-(
Thanks again, G. Vitillaro.
The bug has been closed via the following commit(s):
Author: Andreas Sturmlechner <email@example.com>
AuthorDate: 2019-06-01 08:38:46 +0000
Commit: Andreas Sturmlechner <firstname.lastname@example.org>
CommitDate: 2019-06-01 08:42:37 +0000
kde-apps/messagelib: Fix messagewindow crash with Qt 5.12.3
Reported-by: Erik Quaeghebeur <email@example.com>
Thanks-to: Giuseppe Vitillaro <firstname.lastname@example.org>
Package-Manager: Portage-2.3.67, Repoman-2.3.13
Signed-off-by: Andreas Sturmlechner <email@example.com>
.../messagelib-18.12.3-qtwebengine-5.12.3.patch | 172 +++++++++++++++++++++
kde-apps/messagelib/messagelib-18.12.3-r2.ebuild | 71 +++++++++
2 files changed, 243 insertions(+)
(In reply to Larry the Git Cow from comment #9)
> The bug has been closed via the following commit(s):
> commit a8e77815125e73f7baf630855845a5f4bb041e51
> Author: Andreas Sturmlechner <firstname.lastname@example.org>
> AuthorDate: 2019-06-01 08:38:46 +0000
> Commit: Andreas Sturmlechner <email@example.com>
> CommitDate: 2019-06-01 08:42:37 +0000
> kde-apps/messagelib: Fix messagewindow crash with Qt 5.12.3
> Reported-by: Erik Quaeghebeur <firstname.lastname@example.org>
> Thanks-to: Giuseppe Vitillaro <email@example.com>
> Closes: https://bugs.gentoo.org/686842
> Package-Manager: Portage-2.3.67, Repoman-2.3.13
> Signed-off-by: Andreas Sturmlechner <firstname.lastname@example.org>
> .../messagelib-18.12.3-qtwebengine-5.12.3.patch | 172
> kde-apps/messagelib/messagelib-18.12.3-r2.ebuild | 71 +++++++++
> 2 files changed, 243 insertions(+)
Thanks! I applied the messagelib-18.12.3-qtwebengine-5.12.3.patch published in messagelib-18.12.3-r2 to messagelib-18.12.3-r1, as a user patch, and it works nicely, fixing the problem.
My next June monthly gentoo emerge/update will find it ready in Gentoo portage, if this will be the case.
Fixed! Appreciated! G. Vitillaro.