Commit 6b135af1 authored by Wim Taymans's avatar Wim Taymans
Browse files

metadata: fix properties

The spa_dict does not live outside of the scope it is created in
and so no metadata name is passed to the export function.

Use and initialize a variable outside of the scope instead.
parent 8e7331a2
Pipeline #415835 failed with stages
in 2 minutes and 10 seconds
......@@ -644,7 +644,7 @@ wp_impl_metadata_activate_execute_step (WpObject * object,
g_autoptr (WpCore) core = wp_object_get_core (object);
struct pw_core *pw_core = wp_core_get_pw_core (core);
struct spa_dict_item items[1];
const struct spa_dict *props = NULL;
struct spa_dict *props = NULL, prop_impl;
/* no pw_core -> we are not connected */
if (!pw_core) {
......@@ -660,7 +660,8 @@ wp_impl_metadata_activate_execute_step (WpObject * object,
* yet, so we add the name property manually for now */
if (self->name) {
items[0] = SPA_DICT_ITEM_INIT(PW_KEY_METADATA_NAME, self->name);
props = &SPA_DICT_INIT_ARRAY(items);
prop_impl = SPA_DICT_INIT_ARRAY(items);
props = &prop_impl;
}
wp_proxy_watch_bind_error (WP_PROXY (self), WP_TRANSITION (transition));
wp_proxy_set_pw_proxy (WP_PROXY (self), pw_core_export (pw_core,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment