mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-02 09:01:46 -05:00
- don't call pa_sink_notify in pa_sink_input_new() because the virtual methods are not yet initialized at this time
- some minor cleanups git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1180 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
7f93d08d40
commit
ddc69fccb5
1 changed files with 6 additions and 4 deletions
|
|
@ -135,8 +135,10 @@ pa_sink_input* pa_sink_input_new(
|
|||
pa_log_info(__FILE__": created %u \"%s\" on %u with sample spec \"%s\"", i->index, i->name, s->index, st);
|
||||
|
||||
pa_subscription_post(s->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_NEW, i->index);
|
||||
pa_sink_notify(i->sink);
|
||||
|
||||
/* We do not call pa_sink_notify() here, because the virtual
|
||||
* functions have not yet been initialized */
|
||||
|
||||
return i;
|
||||
}
|
||||
|
||||
|
|
@ -446,7 +448,7 @@ pa_resample_method_t pa_sink_input_get_resample_method(pa_sink_input *i) {
|
|||
assert(i->ref >= 1);
|
||||
|
||||
if (!i->resampler)
|
||||
return PA_RESAMPLER_INVALID;
|
||||
return i->resample_method;
|
||||
|
||||
return pa_resampler_get_method(i->resampler);
|
||||
}
|
||||
|
|
@ -574,9 +576,9 @@ int pa_sink_input_move_to(pa_sink_input *i, pa_sink *dest, int immediately) {
|
|||
}
|
||||
|
||||
/* Okey, let's move it */
|
||||
pa_idxset_remove_by_data(i->sink->inputs, i, NULL);
|
||||
pa_idxset_remove_by_data(origin->inputs, i, NULL);
|
||||
pa_idxset_put(dest->inputs, i, NULL);
|
||||
i->sink = dest;
|
||||
pa_idxset_put(i->sink->inputs, i, NULL);
|
||||
|
||||
/* Replace resampler */
|
||||
if (new_resampler != i->resampler) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue