module-combine-sink: Suspend while unloading to fix crash moving sinks

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/756>
This commit is contained in:
Igor V. Kovalenko 2022-11-27 19:39:23 +03:00
parent 37c72c2072
commit 0cbbc408ae

View file

@ -1733,6 +1733,9 @@ void pa__done(pa_module*m) {
if (!(u = m->userdata))
return;
if (u->sink && PA_SINK_IS_LINKED(u->sink->state))
pa_sink_suspend(u->sink, true, PA_SUSPEND_UNAVAILABLE);
pa_strlist_free(u->unlinked_slaves);
if (u->sink_put_slot)