[FFmpeg-cvslog] scpr: Added missing error check

Derek Buitenhuis git at videolan.org
Fri Jul 7 22:33:36 EEST 2017


ffmpeg | branch: master | Derek Buitenhuis <derek.buitenhuis at gmail.com> | Thu Jul  6 13:47:42 2017 -0400| [f7daed854532628c5e83fb7a5da04ae8916379ff] | committer: Derek Buitenhuis

scpr: Added missing error check

Signed-off-by: Derek Buitenhuis <derek.buitenhuis at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f7daed854532628c5e83fb7a5da04ae8916379ff
---

 libavcodec/scpr.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/scpr.c b/libavcodec/scpr.c
index f6d1e45692..37fbe7a106 100644
--- a/libavcodec/scpr.c
+++ b/libavcodec/scpr.c
@@ -582,6 +582,8 @@ static int decompress_p(AVCodecContext *avctx,
 
                 for (; by < y * 16 + sy2 && by < avctx->height;) {
                     ret = decode_value(s, s->op_model[ptype], 6, 1000, &ptype);
+                    if (ret < 0)
+                        return ret;
                     if (ptype == 0) {
                         ret = decode_unit(s, &s->pixel_model[0][cx + cx1], 400, &r);
                         if (ret < 0)



More information about the ffmpeg-cvslog mailing list