Bug 450195 - crashes at logout
Summary: crashes at logout
Status: RESOLVED FIXED
Alias: None
Product: Bluedevil
Classification: Plasma
Component: daemon (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR crash
Target Milestone: ---
Assignee: David Rosca
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-02-14 05:49 UTC by oneforall
Modified: 2022-02-15 00:14 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.24.1
Sentry Crash Report:


Attachments
logout krash (945 bytes, text/plain)
2022-02-14 05:49 UTC, oneforall
Details

Note You need to log in before you can comment on or make changes to this bug.
Description oneforall 2022-02-14 05:49:24 UTC
Created attachment 146697 [details]
logout krash

SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. logout
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 2 Ahmad Samir 2022-02-14 12:22:36 UTC
Application: kded5 (kded5), signal: Segmentation fault

[KCrash Handler]
#4  0x00007f140407a583 in  () at /usr/lib64/libKF5BluezQt.so.6
#5  0x00007f140407a1d2 in BluezQt::Manager::adapters() const () at /usr/lib64/libKF5BluezQt.so.6
#6  0x00007f14051aee1c in  () at /usr/lib64/qt5/plugins/kf5/kded/bluedevil.so
#7  0x00007f14051af0f7 in  () at /usr/lib64/qt5/plugins/kf5/kded/bluedevil.so
#8  0x00007f14051af129 in  () at /usr/lib64/qt5/plugins/kf5/kded/bluedevil.so
#9  0x00007f1411b6a75e in QObjectPrivate::deleteChildren() () at /usr/lib64/libQt5Core.so.5
#10 0x00007f1411b74b24 in QObject::~QObject() () at /usr/lib64/libQt5Core.so.5
#11 0x00007f14051aae89 in BlueDevilDaemon::~BlueDevilDaemon() () at /usr/lib64/qt5/plugins/kf5/kded/bluedevil.so
#12 0x000000000040918f in  ()
#13 0x000000000040711c in  ()
#14 0x00007f141135b03d in __libc_start_main () at /lib64/libc.so.6
#15 0x00000000004074da in  ()
[Inferior 1 (process 1825) detached]

(Better to post the backtrace directly in a comment, as that makes searching for common strings in it easier with bugzilla search tool).
Comment 3 Nate Graham 2022-02-14 18:25:10 UTC
Git commit fad0578afeb574c5115215aec353d2e35356b9c9 by Nate Graham, on behalf of Fushan Wen.
Committed on 14/02/2022 at 18:25.
Pushed by ngraham into branch 'master'.

kded/devicemonitor: Check BlueDevilDaemon exists when calling login1PrepareForSleep

It's possible that BlueDevilDaemon has been destroyed, but PrepareForSleep
is received before DeviceMonitor is destroyed, so a crash will happen. To prevent
the crash, add a check in login1PrepareForSleep to validate BlueDevilDaemon still exists.
FIXED-IN: 5.24.1

M  +16   -0    src/kded/devicemonitor.cpp
M  +1    -0    src/kded/devicemonitor.h

https://invent.kde.org/plasma/bluedevil/commit/fad0578afeb574c5115215aec353d2e35356b9c9
Comment 4 Nate Graham 2022-02-14 18:25:36 UTC
Git commit 038b7e303f7c1881e53ccd1db4d04e5d1ca3987b by Nate Graham, on behalf of Fushan Wen.
Committed on 14/02/2022 at 18:25.
Pushed by ngraham into branch 'Plasma/5.24'.

kded/devicemonitor: Check BlueDevilDaemon exists when calling login1PrepareForSleep

It's possible that BlueDevilDaemon has been destroyed, but PrepareForSleep
is received before DeviceMonitor is destroyed, so a crash will happen. To prevent
the crash, add a check in login1PrepareForSleep to validate BlueDevilDaemon still exists.
FIXED-IN: 5.24.1


(cherry picked from commit fad0578afeb574c5115215aec353d2e35356b9c9)

M  +16   -0    src/kded/devicemonitor.cpp
M  +1    -0    src/kded/devicemonitor.h

https://invent.kde.org/plasma/bluedevil/commit/038b7e303f7c1881e53ccd1db4d04e5d1ca3987b
Comment 5 oneforall 2022-02-15 00:14:40 UTC
hi patched tested and it works thanks