diff --git a/src/examples/bluez-session.c b/src/examples/bluez-session.c index 041594ac5..fffe2f4ad 100644 --- a/src/examples/bluez-session.c +++ b/src/examples/bluez-session.c @@ -71,6 +71,7 @@ struct impl { struct spa_hook listener; struct spa_list device_list; + struct pw_properties *props; }; static struct node *find_node(struct object *obj, uint32_t id) @@ -302,7 +303,7 @@ static int start_monitor(struct impl *impl) int res; void *iface; - handle = pw_context_load_spa_handle(impl->context, SPA_NAME_API_BLUEZ5_ENUM_DBUS, NULL); + handle = pw_context_load_spa_handle(impl->context, SPA_NAME_API_BLUEZ5_ENUM_DBUS, &impl->props->dict); if (handle == NULL) { res = -errno; goto out; @@ -362,6 +363,10 @@ int main(int argc, char *argv[]) return -1; } + if ((impl.props = pw_properties_new(NULL, NULL)) == NULL) { + return -1; + } + pw_core_add_listener(impl.core, &impl.core_listener, &core_events, &impl);