mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-31 22:25:33 -04:00
split a validity check into two
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1249 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
79cb80c574
commit
e0f7e8614c
1 changed files with 2 additions and 1 deletions
|
|
@ -101,7 +101,8 @@ pa_sink_input* pa_sink_input_new(
|
|||
if (!data->sink)
|
||||
data->sink = pa_namereg_get(core, NULL, PA_NAMEREG_SINK, 1);
|
||||
|
||||
CHECK_VALIDITY_RETURN_NULL(data->sink && data->sink->state == PA_SINK_RUNNING);
|
||||
CHECK_VALIDITY_RETURN_NULL(data->sink);
|
||||
CHECK_VALIDITY_RETURN_NULL(data->sink->state == PA_SINK_RUNNING);
|
||||
|
||||
if (!data->sample_spec_is_set)
|
||||
data->sample_spec = data->sink->sample_spec;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue