mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-05 13:30:02 -05:00
fix some leaks in error paths
This commit is contained in:
parent
6affda9424
commit
669fbf10c1
2 changed files with 3 additions and 3 deletions
|
|
@ -402,7 +402,7 @@ struct module *create_module_combine_sink(struct impl *impl, const char *argumen
|
||||||
struct module_combine_sink_data *d;
|
struct module_combine_sink_data *d;
|
||||||
struct pw_properties *props = NULL;
|
struct pw_properties *props = NULL;
|
||||||
const char *str;
|
const char *str;
|
||||||
char *sink_name, **sink_names = NULL;
|
char *sink_name = NULL, **sink_names = NULL;
|
||||||
struct spa_audio_info_raw info = { 0 };
|
struct spa_audio_info_raw info = { 0 };
|
||||||
int i, n, res;
|
int i, n, res;
|
||||||
|
|
||||||
|
|
@ -461,8 +461,8 @@ struct module *create_module_combine_sink(struct impl *impl, const char *argumen
|
||||||
return module;
|
return module;
|
||||||
out:
|
out:
|
||||||
pw_properties_free(props);
|
pw_properties_free(props);
|
||||||
|
free(sink_name);
|
||||||
pw_free_strv(sink_names);
|
pw_free_strv(sink_names);
|
||||||
errno = -res;
|
errno = -res;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -243,7 +243,7 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
error:
|
error:
|
||||||
|
pw_properties_free(props);
|
||||||
free(impl);
|
free(impl);
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue