aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/tak_parser.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-10-27 22:45:51 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-10-27 23:03:07 +0200
commit189fbcede89bb5d7ec6c3b05d1e30f1bab3a060a (patch)
treeb054db80704d0e1ffac7b5f6b59d3e03f3eaf4b4 /libavcodec/tak_parser.c
parent6078bd80247101db326b40f7e295bbd87b669c18 (diff)
downloadffmpeg-189fbcede89bb5d7ec6c3b05d1e30f1bab3a060a.tar.gz
tak_parser: check ff_combine_frame() return code
Fixes CID733706 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/tak_parser.c')
-rw-r--r--libavcodec/tak_parser.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/tak_parser.c b/libavcodec/tak_parser.c
index dcc37eca8f..55766a4d78 100644
--- a/libavcodec/tak_parser.c
+++ b/libavcodec/tak_parser.c
@@ -66,7 +66,8 @@ static int tak_parse(AVCodecParserContext *s, AVCodecContext *avctx,
int tmp_buf_size = FFMIN(2 * TAK_MAX_FRAME_HEADER_BYTES, buf_size);
const uint8_t *tmp_buf = buf;
- ff_combine_frame(pc, END_NOT_FOUND, &tmp_buf, &tmp_buf_size);
+ if (ff_combine_frame(pc, END_NOT_FOUND, &tmp_buf, &tmp_buf_size) != -1)
+ return AVERROR(ENOMEM);
consumed += tmp_buf_size;
buf += tmp_buf_size;
buf_size -= tmp_buf_size;