mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
echo-cancel: Fail if loaded between a sink and its monitor
Loading between a sink and its monitor causes a deadlock (while sending messages for latency snapshots). It isn't a case that has any real conceivable use, so let's just disallow it.
This commit is contained in:
parent
d086f15c91
commit
e681469154
1 changed files with 5 additions and 0 deletions
|
|
@ -1357,6 +1357,11 @@ int pa__init(pa_module*m) {
|
||||||
}
|
}
|
||||||
pa_assert(sink_master);
|
pa_assert(sink_master);
|
||||||
|
|
||||||
|
if (source_master->monitor_of == sink_master) {
|
||||||
|
pa_log("Can't cancel echo between a sink and its monitor");
|
||||||
|
goto fail;
|
||||||
|
}
|
||||||
|
|
||||||
source_ss = source_master->sample_spec;
|
source_ss = source_master->sample_spec;
|
||||||
source_ss.rate = DEFAULT_RATE;
|
source_ss.rate = DEFAULT_RATE;
|
||||||
source_ss.channels = DEFAULT_CHANNELS;
|
source_ss.channels = DEFAULT_CHANNELS;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue