diff options
author | Steven Liu <lq@chinaffmpeg.org> | 2019-10-10 10:52:52 +0800 |
---|---|---|
committer | Steven Liu <lq@chinaffmpeg.org> | 2019-10-19 06:56:02 +0200 |
commit | b1071b405d57eb980f228f1ef17a97ca69cbf53f (patch) | |
tree | c2f9aee354315240bc396bfb0490d2246373a14c /libavformat | |
parent | 53928e0b49b9924a41905d20a26b965ecdd9abf5 (diff) | |
download | ffmpeg-b1071b405d57eb980f228f1ef17a97ca69cbf53f.tar.gz |
avformat/mvdec: check av_strdup() return value
Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/mvdec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/mvdec.c b/libavformat/mvdec.c index 4f75dcacdb..f9f7e38137 100644 --- a/libavformat/mvdec.c +++ b/libavformat/mvdec.c @@ -211,6 +211,8 @@ static int parse_video_var(AVFormatContext *avctx, AVStream *st, } else if (!strcmp(name, "ORIENTATION")) { if (var_read_int(pb, size) == 1101) { st->codecpar->extradata = av_strdup("BottomUp"); + if (!st->codecpar->extradata) + return AVERROR(ENOMEM); st->codecpar->extradata_size = 9; } } else if (!strcmp(name, "Q_SPATIAL") || !strcmp(name, "Q_TEMPORAL")) { |