Skip to content
Commit b39551b9 authored by Matěj Laitl's avatar Matěj Laitl
Browse files

MediaDeviceTrack: prevent possible crashes, Handler::Capability fixes

When a media device is removed, its collection and handler are
destroyed, but its tracks, albums are kept as long as they are
referenced. Tracks, albums use QWeakPointer to track deletion of
their handler. Ensure that this pointer is always checked before
use in MediaDeviceTrack.

Also ensure that related Capabilities get destroyed (they should
be alredy tracked using QWeakPointer) when handler gets deleted.
It did not work previously in cases when Capabilities were created
in a thread from handler's. Move them to handler's thread so that
parentship can be established.

BUG: 284838
FIXED-IN: 2.5
parent db2b5159
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment