mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-05 23:18:52 +00:00
avcfg: Fix AVOptionRanges leak
It must be freed with av_opt_freep_ranges as documented.
This commit is contained in:
parent
6ffe685b89
commit
a2c88ec9da
1 changed files with 6 additions and 4 deletions
|
@ -252,10 +252,12 @@ install_opts (GObjectClass * gobject_class, const AVClass ** obj, guint prop_id,
|
||||||
if (g_object_class_find_property (gobject_class, name))
|
if (g_object_class_find_property (gobject_class, name))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (av_opt_query_ranges (&r, obj, opt->name, AV_OPT_SEARCH_FAKE_OBJ) >= 0
|
if (av_opt_query_ranges (&r, obj, opt->name, AV_OPT_SEARCH_FAKE_OBJ) >= 0) {
|
||||||
&& r->nb_ranges == 1) {
|
if (r->nb_ranges == 1) {
|
||||||
min = r->range[0]->value_min;
|
min = r->range[0]->value_min;
|
||||||
max = r->range[0]->value_max;
|
max = r->range[0]->value_max;
|
||||||
|
}
|
||||||
|
av_opt_freep_ranges (&r);
|
||||||
}
|
}
|
||||||
|
|
||||||
help = g_strdup_printf ("%s%s", opt->help, extra_help);
|
help = g_strdup_printf ("%s%s", opt->help, extra_help);
|
||||||
|
|
Loading…
Reference in a new issue