Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-04-11 16:08:07 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2017-04-11 22:28:26 +0300
commit9eff4b0d2b5013e1ede86cf1a152dce164217d52 (patch)
tree2d0ca5a1a736bcb84784c6aad3b4ae40858031ff /libavformat/oggparseogm.c
parent170d864d2c508ca8111b1d108e1e964007dab712 (diff)
avformat/oggparseogm: Check ff_alloc_extradata() for failure
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat/oggparseogm.c')
-rw-r--r--libavformat/oggparseogm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/oggparseogm.c b/libavformat/oggparseogm.c
index cdbdfd66e0..e7a501b5a7 100644
--- a/libavformat/oggparseogm.c
+++ b/libavformat/oggparseogm.c
@@ -110,7 +110,8 @@ ogm_header(AVFormatContext *s, int idx)
size -= 52;
if (bytestream2_get_bytes_left(&p) < size)
return AVERROR_INVALIDDATA;
- ff_alloc_extradata(st->codecpar, size);
+ if (ff_alloc_extradata(st->codecpar, size) < 0)
+ return AVERROR(ENOMEM);
bytestream2_get_buffer(&p, st->codecpar->extradata, st->codecpar->extradata_size);
}
}