Bug 456531

Summary: System Settings crashed in KDecoration2::Decoration::shadow() when clicking the "OK" button in Window Decorations settings.
Product: [Applications] systemsettings Reporter: Scott Beamer <scott.beamer>
Component: kcm_kwindecorationAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: crash CC: account4reg, axpanos, bluenerd, contact.gladiusmusic, loup.letac, matetamasi, michael.wiedemayer, nate, opiuy8, plasma-bugs, scott.beamer
Priority: HI Keywords: drkonqi
Version: 5.26.4   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=478558
Latest Commit: Version Fixed In: 6.0.3
Sentry Crash Report:

Description Scott Beamer 2022-07-09 21:01:33 UTC
Application: systemsettings (5.25.2)

Qt Version: 5.15.3
Frameworks Version: 5.94.0
Operating System: Linux 5.18.10-200.fc36.x86_64 x86_64
Windowing System: X11
Distribution: "Fedora release 36 (Thirty Six)"
DrKonqi: 5.25.2 [KCrashBackend]

-- Information about the crash:
I had just changed a Window Decoration settings, then clocked on "OK" to comlete it, and Sthe ystem Settings app crashed.

The reporter is unsure if this crash is reproducible.

-- Backtrace:
Application: System Settings (systemsettings), signal: Segmentation fault

[KCrash Handler]
#4  0x00007f7192a08ea4 in KDecoration2::Decoration::shadow() const () at /lib64/libkdecorations2.so.5
#5  0x00007f7192596a55 in KDecoration2::Preview::PreviewItem::hoverLeaveEvent(QHoverEvent*) () at /usr/lib64/qt5/qml/org/kde/kwin/private/kdecoration/libkdecorationprivatedeclarative.so
#6  0x00007f71e071e378 in QQuickItem::event(QEvent*) () at /lib64/libQt5Quick.so.5
#7  0x00007f71e302dc82 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt5Widgets.so.5
#8  0x00007f71e2457658 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt5Core.so.5
#9  0x00007f71e0738497 in QQuickWindowPrivate::sendHoverEvent(QEvent::Type, QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool) () at /lib64/libQt5Quick.so.5
#10 0x00007f71e073961b in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#11 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#12 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#13 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#14 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#15 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#16 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#17 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#18 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#19 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#20 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#21 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#22 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#23 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#24 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#25 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#26 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#27 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#28 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#29 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#30 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#31 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#32 0x00007f71e0738cd1 in QQuickWindowPrivate::deliverHoverEvent(QQuickItem*, QPointF const&, QPointF const&, QFlags<Qt::KeyboardModifier>, unsigned long, bool&) () at /lib64/libQt5Quick.so.5
#33 0x00007f71e073e80a in QQuickWindowPrivate::handleMouseEvent(QMouseEvent*) () at /lib64/libQt5Quick.so.5
#34 0x00007f71e29bc795 in QWindow::event(QEvent*) () at /lib64/libQt5Gui.so.5
#35 0x00007f71e302dc82 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt5Widgets.so.5
#36 0x00007f71e2457658 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt5Core.so.5
#37 0x00007f71e0a82c7b in QQuickWidget::mouseMoveEvent(QMouseEvent*) () at /lib64/libQt5QuickWidgets.so.5
#38 0x00007f71e3070798 in QWidget::event(QEvent*) () at /lib64/libQt5Widgets.so.5
#39 0x00007f71e302dc82 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt5Widgets.so.5
#40 0x00007f71e3036302 in QApplication::notify(QObject*, QEvent*) () at /lib64/libQt5Widgets.so.5
#41 0x00007f71e2457658 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt5Core.so.5
#42 0x00007f71e3034402 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) () at /lib64/libQt5Widgets.so.5
#43 0x00007f71e3089aec in QWidgetWindow::handleMouseEvent(QMouseEvent*) () at /lib64/libQt5Widgets.so.5
#44 0x00007f71e308ceb0 in QWidgetWindow::event(QEvent*) () at /lib64/libQt5Widgets.so.5
#45 0x00007f71e302dc82 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt5Widgets.so.5
#46 0x00007f71e2457658 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt5Core.so.5
#47 0x00007f71e29b1115 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () at /lib64/libQt5Gui.so.5
#48 0x00007f71e2990f5c in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /lib64/libQt5Gui.so.5
#49 0x00007f71cf8aaaee in xcbSourceDispatch(_GSource*, int (*)(void*), void*) () at /lib64/libQt5XcbQpa.so.5
#50 0x00007f71e0ae1faf in g_main_context_dispatch () at /lib64/libglib-2.0.so.0
#51 0x00007f71e0b372c8 in g_main_context_iterate.constprop () at /lib64/libglib-2.0.so.0
#52 0x00007f71e0adf940 in g_main_context_iteration () at /lib64/libglib-2.0.so.0
#53 0x00007f71e24a82fa in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /lib64/libQt5Core.so.5
#54 0x00007f71e24560ba in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /lib64/libQt5Core.so.5
#55 0x00007f71e245e162 in QCoreApplication::exec() () at /lib64/libQt5Core.so.5
#56 0x000055b8ca9180db in main ()
[Inferior 1 (process 54258) detached]

Reported using DrKonqi
Comment 1 Nicolas Fella 2023-02-26 13:50:10 UTC
*** Bug 465975 has been marked as a duplicate of this bug. ***
Comment 2 Nicolas Fella 2023-02-26 13:50:25 UTC
*** Bug 466471 has been marked as a duplicate of this bug. ***
Comment 3 Nate Graham 2023-03-13 16:43:26 UTC
*** Bug 466993 has been marked as a duplicate of this bug. ***
Comment 4 Nate Graham 2023-03-14 19:55:03 UTC
*** Bug 467339 has been marked as a duplicate of this bug. ***
Comment 5 Nate Graham 2023-03-15 16:14:12 UTC
*** Bug 466485 has been marked as a duplicate of this bug. ***
Comment 6 Nate Graham 2023-04-16 03:40:49 UTC
So far no reports from 5.27.

Is anyone who was able to reproduce this crash in the past still able to do so with Plasma 5.27?
Comment 7 PG 2023-04-17 08:32:12 UTC
If i remember correctly after reporting the bug, it was a version upgrade (plasma 5.26.x to 5.27.x) dependency issue in fedora kde. When you ran the update before the bug appeared some packages needed replacement and their filenames changed (those were some purely qt related packages) but since their filenames changed you had to accept the replacement of those new dependencies overwriting other existing ones with different filenames. I initially did not accept those as i did not know if it would break my system after I saw the warning in dnf. After that I experienced this bug. After upgrading and overwriting the dependency upon experiencing the bug KDE plasma 5.27.x runs smoothly without those filed bug issues.

I hope this helps!
Comment 8 Nate Graham 2023-04-17 13:27:49 UTC
Thanks, that's helpful information. Did anyone else experience anything similar?
Comment 9 Nate Graham 2023-12-15 22:28:20 UTC
Apparently not, which means I think we can say this was fixed at some point in the past, and your issue was a transient upgrade issue, PG.
Comment 10 Nate Graham 2024-03-05 23:52:35 UTC
*** Bug 482340 has been marked as a duplicate of this bug. ***
Comment 11 Nate Graham 2024-03-05 23:53:55 UTC
Got a new report with the same backtrace in Plasma 6: Bug 482340. Re-opening. And on Wayland too, so it doesn't look to be X11-specific.
Comment 12 Nicolas Fella 2024-03-22 12:35:44 UTC
*** Bug 483849 has been marked as a duplicate of this bug. ***
Comment 13 Nicolas Fella 2024-03-22 12:35:56 UTC
*** Bug 483792 has been marked as a duplicate of this bug. ***
Comment 14 Bug Janitor Service 2024-03-22 12:44:57 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/5507
Comment 15 Nicolas Fella 2024-03-22 12:54:19 UTC
Git commit 0fef229587d642e6175f39abc45fc839baffe1f1 by Nicolas Fella.
Committed on 22/03/2024 at 12:42.
Pushed by nicolasfella into branch 'master'.

kcms/decoration: Fix crash when preview cannot be generated

m_bridge->createDecoration() can return nullptr. Most codepaths
already guard against that, but not all of them

M  +12   -8    src/kcms/decoration/declarative-plugin/previewitem.cpp

https://invent.kde.org/plasma/kwin/-/commit/0fef229587d642e6175f39abc45fc839baffe1f1
Comment 16 Nicolas Fella 2024-03-22 13:10:01 UTC
Git commit d8019dbf168cf5330f65603ce7a8161443554e3d by Nicolas Fella.
Committed on 22/03/2024 at 12:58.
Pushed by nicolasfella into branch 'Plasma/6.0'.

kcms/decoration: Fix crash when preview cannot be generated

m_bridge->createDecoration() can return nullptr. Most codepaths
already guard against that, but not all of them
(cherry picked from commit 0fef229587d642e6175f39abc45fc839baffe1f1)

M  +12   -8    src/kcms/decoration/declarative-plugin/previewitem.cpp

https://invent.kde.org/plasma/kwin/-/commit/d8019dbf168cf5330f65603ce7a8161443554e3d