[FFmpeg-cvslog] avcodec/svq1dec: Check init_get_bits8() for failure
Michael Niedermayer
git at videolan.org
Thu Nov 19 11:27:51 CET 2015
ffmpeg | branch: release/2.6 | Michael Niedermayer <michael at niedermayer.cc> | Fri Sep 4 01:18:13 2015 +0200| [a2e0602157ad4813f6d1709d805429206ef70f43] | committer: Michael Niedermayer
avcodec/svq1dec: Check init_get_bits8() for failure
Fixes: CID1322313
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit a51d4246d8ac96acee735e7e5dedb9d9ef27a594)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a2e0602157ad4813f6d1709d805429206ef70f43
---
libavcodec/svq1dec.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libavcodec/svq1dec.c b/libavcodec/svq1dec.c
index a95c7c8..0af4708 100644
--- a/libavcodec/svq1dec.c
+++ b/libavcodec/svq1dec.c
@@ -616,9 +616,12 @@ static int svq1_decode_frame(AVCodecContext *avctx, void *data,
uint8_t *current;
int result, i, x, y, width, height;
svq1_pmv *pmv;
+ int ret;
/* initialize bit buffer */
- init_get_bits8(&s->gb, buf, buf_size);
+ ret = init_get_bits8(&s->gb, buf, buf_size);
+ if (ret < 0)
+ return ret;
/* decode frame header */
s->frame_code = get_bits(&s->gb, 22);
More information about the ffmpeg-cvslog
mailing list