mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
sink-input: change bool save_sink to char *preferred_sink
The finial objective is to store the preferred sink name in the sink-input struct, and use module-stream-restore to save and restore it. This patch just replaces the save_sink with preferred_sink, and tries to keep the original logic. Signed-off-by: Hui Wang <hui.wang@canonical.com>
This commit is contained in:
parent
26a66d103f
commit
fbf8716685
6 changed files with 55 additions and 28 deletions
|
|
@ -175,14 +175,14 @@ static pa_hook_result_t sink_put_hook_callback(pa_core *c, pa_sink *sink, struct
|
|||
if (si->sink == sink)
|
||||
continue;
|
||||
|
||||
if (si->save_sink)
|
||||
continue;
|
||||
|
||||
/* Skip this if it is already in the process of being moved
|
||||
* anyway */
|
||||
if (!si->sink)
|
||||
continue;
|
||||
|
||||
if (pa_safe_streq(si->sink->name, si->preferred_sink))
|
||||
continue;
|
||||
|
||||
/* It might happen that a stream and a sink are set up at the
|
||||
same time, in which case we want to make sure we don't
|
||||
interfere with that */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue