https://bugs.kde.org/show_bug.cgi?id=494224

Nicolas Fella <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
      Latest Commit|                            |https://invent.kde.org/fram
                   |                            |eworks/solid/-/commit/1348d
                   |                            |32ca17e6b026c8925778939ea24
                   |                            |ed63eaad
             Status|REPORTED                    |RESOLVED

--- Comment #17 from Nicolas Fella <[email protected]> ---
Git commit 1348d32ca17e6b026c8925778939ea24ed63eaad by Nicolas Fella.
Committed on 21/01/2026 at 10:48.
Pushed by nicolasfella into branch 'master'.

Use delete instead of deleteLater() when DevicePrivate refcount drops to 0

When the last interface of a udisk device is removed we emit deviceRemoved(),
which results in setBackendObject(nullptr). There we deref the deviceprivate
and delete if necessary.

By using deleteLater() the deletion is delayed, which can cause issues
where the Device accesses an already deleted DevicePrivate.

By using delete instead we make sure that the DevicePrivate is immediately
deleted and removed from m_devicesMap

Remove an assert in DeviceManager since dev may already be deleted now
Related: bug 513508, bug 470321, bug 513089, bug 513921

M  +1    -1    src/solid/devices/frontend/device.cpp
M  +0    -1    src/solid/devices/frontend/devicemanager.cpp

https://invent.kde.org/frameworks/solid/-/commit/1348d32ca17e6b026c8925778939ea24ed63eaad

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to