Summary: | Plasma crashed in the background in PowerDevil::Core::unloadAllActiveActions() when user was switched | ||
---|---|---|---|
Product: | [Plasma] Powerdevil | Reporter: | Jonathan <jonathanrobertbell> |
Component: | general | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | jpetso, jtamate, kde, liangrui.ch, natalie_clarius, nate, stakanov.s |
Priority: | HI | Keywords: | drkonqi |
Version: | 6.1.4 | ||
Target Milestone: | --- | ||
Platform: | Arch Linux | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/plasma/powerdevil/-/commit/29f9b949c3ad75f11499825c79ba2a39344a26b0 | Version Fixed In: | 6.2.5 |
Sentry Crash Report: | https://crash-reports.kde.org/organizations/kde/issues/43977/events/ed729be74d5c44e8b6a542698f5579c6/ |
Description
Jonathan
2024-08-29 05:51:40 UTC
*** Bug 492494 has been marked as a duplicate of this bug. *** *** Bug 493015 has been marked as a duplicate of this bug. *** Sentry said this showed up in Plasma 6.1.2. https://invent.kde.org/plasma/powerdevil/-/commit/d91bc62fa6ff93ac62ded148fee3722deab41442 was shipped in that release and looks like it could be relevant. (In reply to Nate Graham from comment #3) > Sentry said this showed up in Plasma 6.1.2. > https://invent.kde.org/plasma/powerdevil/-/commit/ > d91bc62fa6ff93ac62ded148fee3722deab41442 was shipped in that release and > looks like it could be relevant. Also relevant though: https://invent.kde.org/plasma/powerdevil/-/commit/7a929fa01ed036f60c5a15c72416b4e40eb03160 Which according to its linked bug reports shipped in 6.1.4. *** Bug 495856 has been marked as a duplicate of this bug. *** *** Bug 496146 has been marked as a duplicate of this bug. *** *** Bug 496203 has been marked as a duplicate of this bug. *** *** Bug 496637 has been marked as a duplicate of this bug. *** A possibly relevant merge request was started @ https://invent.kde.org/plasma/powerdevil/-/merge_requests/478 Git commit 41b4ca1dc515b1e44b31f6c4b5eadeb8571cd8f8 by Jakob Petsovits. Committed on 17/12/2024 at 02:33. Pushed by jpetso into branch 'master'. daemon: Don't crash in PowerDevil::Core::unloadAllActiveActions() Commit 584cfdf0 introduced the daemon's ability to remove actions from `Core::m_actionPool` if they become unsupported at runtime. Commit 7a929fa0 fixed some resulting crashes by also cleaning up related map/set elements that contained this action. That was not enough, we got lots of crashes coming in since then. The (many) remaining crashes happened in `unloadAllActiveActions()`, which cycles through `Core::m_activeActions` and accesses the corresponding action pointer in `m_actionPool`. The implication is that `m_activeActions` contains action IDs that are not present in `m_actionPool`. And indeed, commit 7a929fa0 missed cleaning up the action ID corresponding to the now-unsupported action. With the dangling ID removed, PowerDevil should finally stop crashing. SENTRY: FALLTHROUGH-30F M +4 -4 daemon/powerdevilcore.cpp https://invent.kde.org/plasma/powerdevil/-/commit/41b4ca1dc515b1e44b31f6c4b5eadeb8571cd8f8 Git commit 29f9b949c3ad75f11499825c79ba2a39344a26b0 by Jakob Petsovits. Committed on 17/12/2024 at 02:50. Pushed by jpetso into branch 'Plasma/6.2'. daemon: Don't crash in PowerDevil::Core::unloadAllActiveActions() Commit 584cfdf0 introduced the daemon's ability to remove actions from `Core::m_actionPool` if they become unsupported at runtime. Commit 7a929fa0 fixed some resulting crashes by also cleaning up related map/set elements that contained this action. That was not enough, we got lots of crashes coming in since then. The (many) remaining crashes happened in `unloadAllActiveActions()`, which cycles through `Core::m_activeActions` and accesses the corresponding action pointer in `m_actionPool`. The implication is that `m_activeActions` contains action IDs that are not present in `m_actionPool`. And indeed, commit 7a929fa0 missed cleaning up the action ID corresponding to the now-unsupported action. With the dangling ID removed, PowerDevil should finally stop crashing. SENTRY: FALLTHROUGH-30F (cherry picked from commit 41b4ca1dc515b1e44b31f6c4b5eadeb8571cd8f8) Co-authored-by: Jakob Petsovits <jpetso@petsovits.com> M +4 -4 daemon/powerdevilcore.cpp https://invent.kde.org/plasma/powerdevil/-/commit/29f9b949c3ad75f11499825c79ba2a39344a26b0 |