diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-03-29 05:03:56 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-01 04:09:18 +0200 |
commit | a500b975a87174f1994cf497892c2529cf42e834 (patch) | |
tree | b14bbff2e8c2d08d1649ef50b61c59b9b7ef8eb0 /libavcodec/lossless_videodsp.h | |
parent | edee0d01048d26947053ca1657f11f65c21bd7bd (diff) | |
download | ffmpeg-a500b975a87174f1994cf497892c2529cf42e834.tar.gz |
avutil/opt: Don't use NULL for %s string in a log message
If one calls av_opt_set() with an incorrect string to set the value of
an option of type AV_OPT_TYPE_VIDEO_RATE, the given string is used in a
log message via %s. This also happens when the string is actually a
nullpointer in which case using it for %s is forbidden.
This commit changes this by erroring out early in case of a nullpointer.
This also fixes a warning from GCC 9.2:
"ā%sā directive argument is null [-Wformat-overflow=]"
Reviewed-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/lossless_videodsp.h')
0 files changed, 0 insertions, 0 deletions