diff --git a/src/context.c b/src/context.c index 48c6821f1..5e502e92b 100644 --- a/src/context.c +++ b/src/context.c @@ -588,9 +588,11 @@ static int set_mask(pa_context *c, struct global *g) g->link_info.dst->parent_id, g->link_info.dst->id); - if ((f = pa_context_find_global(c, g->link_info.src->parent_id)) != NULL) + if ((f = pa_context_find_global(c, g->link_info.src->parent_id)) != NULL && + !f->init) emit_event(c, f, PA_SUBSCRIPTION_EVENT_CHANGE); - if ((f = pa_context_find_global(c, g->link_info.dst->parent_id)) != NULL) + if ((f = pa_context_find_global(c, g->link_info.dst->parent_id)) != NULL && + !f->init) emit_event(c, f, PA_SUBSCRIPTION_EVENT_CHANGE); break; diff --git a/src/introspect.c b/src/introspect.c index ba3105756..0567e4421 100644 --- a/src/introspect.c +++ b/src/introspect.c @@ -1424,7 +1424,7 @@ struct sink_input_data { static void sink_input_callback(struct sink_input_data *d) { - struct global *g = d->global, *l, *cl; + struct global *g = d->global, *cl; struct pw_node_info *info = g->info; const char *name; pa_sink_input_info i; @@ -1455,6 +1455,7 @@ static void sink_input_callback(struct sink_input_data *d) i.sink = s->device_index; } else { + struct global *l; l = pa_context_find_linked(d->context, g->id); i.sink = l ? l->id : PA_INVALID_INDEX; } @@ -1490,6 +1491,8 @@ static void sink_input_callback(struct sink_input_data *d) i.has_volume = true; i.volume_writable = true; + pw_log_debug("context %p: sink info for %d sink:%d", g->context, i.index, i.sink); + d->cb(d->context, &i, 0, d->userdata); pa_proplist_free(i.proplist);