Bug 422418 - Plasma crashes in ShellCorona::handleScreenRemoved() when I set multi-monitor mode to "Switch to external screen"
Summary: Plasma crashes in ShellCorona::handleScreenRemoved() when I set multi-monitor...
Status: RESOLVED DUPLICATE of bug 356394
Alias: None
Product: plasmashell
Classification: Plasma
Component: generic-multiscreen (show other bugs)
Version: master
Platform: unspecified Linux
: NOR crash
Target Milestone: 1.0
Assignee: Aleix Pol
URL:
Keywords: drkonqi, wayland
Depends on:
Blocks:
 
Reported: 2020-06-03 13:31 UTC by Patrick Silva
Modified: 2021-08-24 13:43 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Silva 2020-06-03 13:31:39 UTC
Application: plasmashell (5.19.80)

Qt Version: 5.14.2
Frameworks Version: 5.71.0
Operating System: Linux 5.3.0-45-generic x86_64
Windowing system: Wayland
Distribution: KDE neon Unstable Edition

-- Information about the crash:
- What I was doing when the application crashed:
I was using the laptop screen, I switched to "Switch to external screen" multi-monitor mode and system tray shown drkonqi icon.

The crash can be reproduced sometimes.

-- Backtrace:
Application: Plasma (plasmashell), signal: Segmentation fault
Content of s_kcrashErrorMessage: [Current thread is 1 (Thread 0x7fd49d401c80 (LWP 13276))]
[KCrash Handler]
#6  0x00007fd497a136c0 in QScreen::refreshRate() const (this=0x0) at kernel/qscreen.cpp:556
#7  0x00007fd49b2fec9c in qsgrl_animation_interval () at scenegraph/qsgthreadedrenderloop.cpp:123
#8  0x00007fd49b2fec9c in QSGThreadedRenderLoop::startOrStopAnimationTimer() (this=this@entry=0x5626c1691090) at scenegraph/qsgthreadedrenderloop.cpp:1112
#9  0x00007fd49b302f74 in QSGThreadedRenderLoop::windowDestroyed(QQuickWindow*) (this=0x5626c1691090, window=0x5626c24cf910) at scenegraph/qsgthreadedrenderloop.cpp:1170
#10 0x00007fd49b35d242 in QQuickWindow::~QQuickWindow() (this=0x5626c24cf910, __in_chrg=<optimized out>) at items/qquickwindow.cpp:1419
#11 0x00005626bf1768b9 in PanelView::~PanelView() (this=0x5626c24cf910, __in_chrg=<optimized out>) at ./shell/panelview.cpp:123
#12 0x00005626bf18364c in ShellCorona::removeDesktop(DesktopView*) (this=this@entry=0x5626c11fba70, desktopView=0x5626c239dea0) at ./shell/shellcorona.cpp:1152
#13 0x00005626bf1836a2 in ShellCorona::handleScreenRemoved(QScreen*) (this=0x5626c11fba70, screen=<optimized out>) at ./shell/shellcorona.cpp:1188
#14 0x00007fd4974296d7 in QtPrivate::QSlotObjectBase::call(QObject*, void**) (a=0x7ffe86f120e0, r=0x5626c11fba70, this=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:398
#15 0x00007fd4974296d7 in doActivate<false>(QObject*, int, void**) (sender=0x7ffe86f128d0, signal_index=10, argv=0x7ffe86f120e0) at kernel/qobject.cpp:3870
#16 0x00007fd497423f92 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (sender=<optimized out>, m=m@entry=0x7fd4981645a0 <QGuiApplication::staticMetaObject>, local_signal_index=local_signal_index@entry=2, argv=argv@entry=0x7ffe86f120e0) at kernel/qobject.cpp:3930
#17 0x00007fd4979df202 in QGuiApplication::screenRemoved(QScreen*) (this=<optimized out>, _t1=<optimized out>) at .moc/moc_qguiapplication.cpp:396
#18 0x00007fd497a1450c in QScreen::~QScreen() (this=0x5626c11daa70, __in_chrg=<optimized out>) at kernel/qscreen.cpp:126
#19 0x00007fd497a14609 in QScreen::~QScreen() (this=0x5626c11daa70, __in_chrg=<optimized out>) at kernel/qscreen.cpp:148
#20 0x00007fd4979c46b7 in QWindowSystemInterface::handleScreenRemoved(QPlatformScreen*) (platformScreen=0x5626c11dc4e0) at kernel/qwindowsysteminterface.cpp:840
#21 0x00007fd48a7db5c0 in QtWaylandClient::QWaylandDisplay::registry_global_remove(unsigned int) (this=0x5626c11d4230, id=<optimized out>) at qwaylanddisplay.cpp:365
#22 0x00007fd48ffb0dae in ffi_call_unix64 () at /usr/lib/x86_64-linux-gnu/libffi.so.6
#23 0x00007fd48ffb071f in ffi_call () at /usr/lib/x86_64-linux-gnu/libffi.so.6
#24 0x00007fd495bf5e24 in wl_closure_invoke (closure=closure@entry=0x5626c3087960, flags=flags@entry=1, target=<optimized out>, target@entry=0x5626c11d60b0, opcode=opcode@entry=1, data=<optimized out>) at ../src/connection.c:1006
#25 0x00007fd495bf2659 in dispatch_event (display=display@entry=0x5626c11d8920, queue=<optimized out>) at ../src/wayland-client.c:1427
#26 0x00007fd495bf3b24 in dispatch_queue (queue=0x5626c11d89e8, display=0x5626c11d8920) at ../src/wayland-client.c:1573
#27 0x00007fd495bf3b24 in wl_display_dispatch_queue_pending (display=0x5626c11d8920, queue=0x5626c11d89e8) at ../src/wayland-client.c:1815
#28 0x00007fd495bf3b7c in wl_display_dispatch_pending (display=<optimized out>) at ../src/wayland-client.c:1878
#29 0x00007fd48a7d9642 in QtWaylandClient::QWaylandDisplay::flushRequests() (this=0x5626c11d4230) at qwaylanddisplay.cpp:208
#30 0x00007fd4974294b9 in doActivate<false>(QObject*, int, void**) (sender=0x5626c120b4c0, signal_index=4, argv=0x7ffe86f12640) at kernel/qobject.cpp:3882
#31 0x00007fd497423f92 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (sender=sender@entry=0x5626c120b4c0, m=m@entry=0x7fd4978bc220 <QAbstractEventDispatcher::staticMetaObject>, local_signal_index=local_signal_index@entry=1, argv=argv@entry=0x0) at kernel/qobject.cpp:3930
#32 0x00007fd4973eaba3 in QAbstractEventDispatcher::awake() (this=this@entry=0x5626c120b4c0) at .moc/moc_qabstracteventdispatcher.cpp:149
#33 0x00007fd49744d7eb in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x5626c120b4c0, flags=...) at kernel/qeventdispatcher_glib.cpp:430
#34 0x00007fd4973ecd2a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=this@entry=0x7ffe86f12760, flags=..., flags@entry=...) at kernel/qeventloop.cpp:225
#35 0x00007fd4973f64a0 in QCoreApplication::exec() () at kernel/qcoreapplication.cpp:1383
#36 0x00005626bf1670ca in main(int, char**) (argc=<optimized out>, argv=<optimized out>) at ./shell/main.cpp:222

Possible duplicates by query: bug 419060, bug 418477, bug 397477, bug 364843, bug 362004.

Reported using DrKonqi
Comment 1 Nate Graham 2021-02-25 21:11:46 UTC
*** Bug 431388 has been marked as a duplicate of this bug. ***
Comment 2 Nate Graham 2021-06-15 23:17:52 UTC
*** Bug 438517 has been marked as a duplicate of this bug. ***
Comment 3 David Edmundson 2021-08-24 13:42:32 UTC

*** This bug has been marked as a duplicate of bug 356394 ***
Comment 4 David Edmundson 2021-08-24 13:43:59 UTC
Though it's also super wrong that we're doing 

#13 0x00005626bf1836a2 in ShellCorona::handleScreenRemoved(QScreen*) (this=0x5626c11fba70, screen=<optimized out>) at ./shell/shellcorona.cpp:1188

in response to

#18 0x00007fd497a1450c in QScreen::~QScreen() (this=0x5626c11daa70, __in_chrg=<optimized out>) at kernel/qscreen.cpp:126

now QGuiApplication::screenRemoved which comes way before object destruction. I'm sure that's fixed in Plasma