Bug 439551 - Crash when closing window
Summary: Crash when closing window
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR crash
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-06 11:19 UTC by Martin Sandsmark
Modified: 2021-07-19 20:29 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
attachment-2828-0.html (2.93 KB, text/html)
2021-07-06 11:21 UTC, tcanabrava
Details
attachment-4846-0.html (1.57 KB, text/html)
2021-07-06 11:35 UTC, tcanabrava
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Sandsmark 2021-07-06 11:19:44 UTC
All my Konsole windows went away when I closed one of them.

Git sha1 036e4e87

Thread 1 (Thread 0x7f9946445a80 (LWP 80757)):
#0  0x00007f994c82be80 in QWidget::window() const () from /usr/lib/libQt5Widgets.so.5
#1  0x00007f9945e61c50 in QWidget::topLevelWidget (this=<optimized out>) at /usr/include/qt/QtWidgets/qwidget.h:309
#2  SSHManagerPlugin::activeViewChanged (this=0x562d6384ad00, controller=0x562d644ab570) at /usr/src/debug/konsole/src/plugins/SSHManager/sshmanagerplugin.cpp:80
#3  0x00007f994bcbf7c3 in ?? () from /usr/lib/libQt5Core.so.5
#4  0x00007f994bcb141f in QObject::event(QEvent*) () from /usr/lib/libQt5Core.so.5
#5  0x00007f994c801d62 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5
#6  0x00007f994bc843aa in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#7  0x00007f994bcdc34d in QTimerInfoList::activateTimers() () from /usr/lib/libQt5Core.so.5
#8  0x00007f994bcda829 in QEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#9  0x00007f9945d6f37f in ?? () from /usr/lib/libQt5XcbQpa.so.5
#10 0x00007f994bc82d1c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#11 0x00007f994bc8b284 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5
#12 0x0000562d6185863a in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/konsole/src/main.cpp:220
Comment 1 tcanabrava 2021-07-06 11:21:43 UTC
Created attachment 139891 [details]
attachment-2828-0.html

This is my fault, I'll fix this today.


On Tue, Jul 6, 2021 at 12:19 PM Martin Sandsmark <bugzilla_noreply@kde.org>
wrote:

> https://bugs.kde.org/show_bug.cgi?id=439551
>
>             Bug ID: 439551
>            Summary: Crash when closing window
>            Product: konsole
>            Version: unspecified
>           Platform: Other
>                 OS: Linux
>             Status: REPORTED
>           Severity: crash
>           Priority: NOR
>          Component: general
>           Assignee: konsole-devel@kde.org
>           Reporter: martin.sandsmark@kde.org
>   Target Milestone: ---
>
> All my Konsole windows went away when I closed one of them.
>
> Git sha1 036e4e87
>
> Thread 1 (Thread 0x7f9946445a80 (LWP 80757)):
> #0  0x00007f994c82be80 in QWidget::window() const () from
> /usr/lib/libQt5Widgets.so.5
> #1  0x00007f9945e61c50 in QWidget::topLevelWidget (this=<optimized out>) at
> /usr/include/qt/QtWidgets/qwidget.h:309
> #2  SSHManagerPlugin::activeViewChanged (this=0x562d6384ad00,
> controller=0x562d644ab570) at
> /usr/src/debug/konsole/src/plugins/SSHManager/sshmanagerplugin.cpp:80
> #3  0x00007f994bcbf7c3 in ?? () from /usr/lib/libQt5Core.so.5
> #4  0x00007f994bcb141f in QObject::event(QEvent*) () from
> /usr/lib/libQt5Core.so.5
> #5  0x00007f994c801d62 in QApplicationPrivate::notify_helper(QObject*,
> QEvent*)
> () from /usr/lib/libQt5Widgets.so.5
> #6  0x00007f994bc843aa in QCoreApplication::notifyInternal2(QObject*,
> QEvent*)
> () from /usr/lib/libQt5Core.so.5
> #7  0x00007f994bcdc34d in QTimerInfoList::activateTimers() () from
> /usr/lib/libQt5Core.so.5
> #8  0x00007f994bcda829 in
> QEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)
> ()
> from /usr/lib/libQt5Core.so.5
> #9  0x00007f9945d6f37f in ?? () from /usr/lib/libQt5XcbQpa.so.5
> #10 0x00007f994bc82d1c in
> QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from
> /usr/lib/libQt5Core.so.5
> #11 0x00007f994bc8b284 in QCoreApplication::exec() () from
> /usr/lib/libQt5Core.so.5
> #12 0x0000562d6185863a in main (argc=<optimized out>, argv=<optimized
> out>) at
> /usr/src/debug/konsole/src/main.cpp:220
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
Comment 2 Martin Sandsmark 2021-07-06 11:25:26 UTC
I see that the crash seems to happen in some plugin, but I can't find anywhere to disable or enable/add or remove plugins. Am I hitting a bug, or isn't there a way to do this?

There has also been some regression in performance (delaying time-to-first-show noticeably), so it would be nice to test if this is the root cause. It seems plausible because the normal launch code doesn't seem to take much longer.
Comment 3 tcanabrava 2021-07-06 11:35:36 UTC
Created attachment 139892 [details]
attachment-4846-0.html

Currently there's no way to disable the plugins, I'm working on it.

you can delete the ssh manager plugin so it won't get loaded until I fix
this issue.
I don't think the plugin would cause a delay on time to first show, there's
nothing related to that on the plugin - it merely presents a treeview for
ssh connections.



On Tue, Jul 6, 2021 at 12:25 PM Martin Sandsmark <bugzilla_noreply@kde.org>
wrote:

> https://bugs.kde.org/show_bug.cgi?id=439551
>
> --- Comment #2 from Martin Sandsmark <martin.sandsmark@kde.org> ---
> I see that the crash seems to happen in some plugin, but I can't find
> anywhere
> to disable or enable/add or remove plugins. Am I hitting a bug, or isn't
> there
> a way to do this?
>
> There has also been some regression in performance (delaying
> time-to-first-show
> noticeably), so it would be nice to test if this is the root cause. It
> seems
> plausible because the normal launch code doesn't seem to take much longer.
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
Comment 4 Martin Sandsmark 2021-07-10 09:45:56 UTC
(In reply to tcanabrava from comment #3)
> Created attachment 139892 [details]
> attachment-4846-0.html
> 
> Currently there's no way to disable the plugins, I'm working on it.
> 
> you can delete the ssh manager plugin so it won't get loaded until I fix
> this issue.
> I don't think the plugin would cause a delay on time to first show, there's
> nothing related to that on the plugin - it merely presents a treeview for
> ssh connections.

It has a ton of symbols that need to be resolved, and I don't think ld can reuse the resolution from konsole itself.

But it's a separate issue anyways, this crash is more critical since it happens all the time.
Comment 5 Martin Sandsmark 2021-07-10 10:42:45 UTC
Hmm, didn't automatically get commented here, but opened a MR that I think fixes it https://invent.kde.org/utilities/konsole/-/merge_requests/436
Comment 6 tcanabrava 2021-07-16 10:47:55 UTC
Git commit 1946d32d242bbfcf4d25f1eec098cf0c34280940 by Tomaz  Canabrava, on behalf of Martin T. H. Sandsmark.
Committed on 16/07/2021 at 10:47.
Pushed by tcanabrava into branch 'master'.

Fix one crash in the sshmanager plugin

M  +20   -2    src/plugins/SSHManager/sshmanagerplugin.cpp
M  +3    -0    src/plugins/SSHManager/sshmanagerplugin.h

https://invent.kde.org/utilities/konsole/commit/1946d32d242bbfcf4d25f1eec098cf0c34280940
Comment 7 Kurt Hindenburg 2021-07-19 20:29:59 UTC
Git commit 94e4285da0acee4ff94ccb54583eaafda40a8958 by Kurt Hindenburg, on behalf of Martin T. H. Sandsmark.
Committed on 19/07/2021 at 20:16.
Pushed by hindenburg into branch 'release/21.08'.

Fix one crash in the sshmanager plugin
(cherry picked from commit 1946d32d242bbfcf4d25f1eec098cf0c34280940)

M  +20   -2    src/plugins/SSHManager/sshmanagerplugin.cpp
M  +3    -0    src/plugins/SSHManager/sshmanagerplugin.h

https://invent.kde.org/utilities/konsole/commit/94e4285da0acee4ff94ccb54583eaafda40a8958