context: ensure the registry exists

Make sure we are watching the registry before we try to enumerate
objects.
When we wait for new object info, resync the pending operations
because they might depend on the info.
This commit is contained in:
Wim Taymans 2020-06-24 14:23:41 +02:00
parent d560499054
commit 5feedbfd42
4 changed files with 44 additions and 13 deletions

View file

@ -52,7 +52,7 @@ pa_operation *pa_operation_new(pa_context *c, pa_stream *s, pa_operation_cb_t cb
int pa_operation_sync(pa_operation *o)
{
pa_context *c = o->context;
o->seq = pw_core_sync(c->core, 0, 0);
o->seq = pw_core_sync(c->core, PW_ID_CORE, 0);
pw_log_debug("operation %p: sync %d", o, o->seq);
return 0;
}