pipewire: fix UAF when pipewire device is removed


In the PipeWire audio backend, when the output device is removed,
handleDeviceRemoved() reported the I/O error to the frontend, but never
disconnected the backend stream's own connections to it. If the app
deletes the QAudioSink from its error/state-changed handler, the backend
stream object survives. Requesting the stream to stop and disconnecting
the QIODevice before propagating the error to the user.

Fixes: QTBUG-150678
Pick-to: 6.12
Change-Id: I4ccf2ceb0f210713fa1ba322a565269be32e296d
Reviewed-by: Artem Dyomin <artem.dyomin@qt.io>
commit8e7f6edf9a04d6c6484ecebca1227c06ec3b3640
parent7835958fe6c0bbc23545e1929ef4e308aa20e5e7
authorTim Blechmann <tim.blechmann@qt.io>
committerTim Blechmann <tim.blechmann@qt.io>
commit timeThu, 1 Oct 2026 08:42:17 +0000