mirror of https://git.ffmpeg.org/ffmpeg.git
avutil/opt: Fix AV_OPT_TYPE_BINARY case in av_opt_is_set_to_default()
Fixes CID1257010 Reviewed-by: Lukasz Marek <lukasz.m.luki2@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
9bd8f2cc32
commit
41a52740d4
|
@ -1788,9 +1788,9 @@ int av_opt_is_set_to_default(void *obj, const AVOption *o)
|
|||
} tmp = {0};
|
||||
int opt_size = *(int *)((void **)dst + 1);
|
||||
void *opt_ptr = *(void **)dst;
|
||||
if (!opt_ptr && (!o->default_val.str || !strlen(o->default_val.str)))
|
||||
if (!opt_size && (!o->default_val.str || !strlen(o->default_val.str)))
|
||||
return 1;
|
||||
if (opt_ptr && o->default_val.str && !strlen(o->default_val.str))
|
||||
if (!opt_size || !o->default_val.str || !strlen(o->default_val.str ))
|
||||
return 0;
|
||||
if (opt_size != strlen(o->default_val.str) / 2)
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue