[FFmpeg-cvslog] avcodec/dfa: Fix signed integer overflow: -2147483648 - 1 cannot be represented in type 'int'
Michael Niedermayer
git at videolan.org
Sat May 6 18:12:16 EEST 2017
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Sat May 6 16:38:22 2017 +0200| [12936a4585bc293c0f88327d6840f49e8e744b62] | committer: Michael Niedermayer
avcodec/dfa: Fix signed integer overflow: -2147483648 - 1 cannot be represented in type 'int'
Fixes: 1368/clusterfuzz-testcase-minimized-4507293276176384
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=12936a4585bc293c0f88327d6840f49e8e744b62
---
libavcodec/dfa.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libavcodec/dfa.c b/libavcodec/dfa.c
index 5ddb647c4c..3ea12f0511 100644
--- a/libavcodec/dfa.c
+++ b/libavcodec/dfa.c
@@ -67,7 +67,8 @@ static int decode_tsw1(GetByteContext *gb, uint8_t *frame, int width, int height
const uint8_t *frame_start = frame;
const uint8_t *frame_end = frame + width * height;
int mask = 0x10000, bitbuf = 0;
- int v, count, segments;
+ int v, count;
+ unsigned segments;
unsigned offset;
segments = bytestream2_get_le32(gb);
More information about the ffmpeg-cvslog
mailing list