ffmpeg/libavcodec
Andreas Cadhalpun 073fcfe358 mjpegdec: consider chroma subsampling in size check
If the chroma components are subsampled, smaller buffers are allocated
for them. In that case the maximal block_offset for the chroma
components is not as large as for the luma component.

This fixes out of bounds writes causing segmentation faults or memory
corruption.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
(cherry picked from commit 5adb5d9d894aa495e7bf9557b4c78350cbfc9d32)

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-12-07 01:34:16 +01:00
..
2015-03-29 03:34:22 +02:00
2015-08-20 14:29:11 +02:00
2015-08-20 14:29:11 +02:00
2014-10-04 23:52:28 +02:00
2015-06-01 23:25:21 +02:00
2015-06-01 23:25:21 +02:00
2015-08-20 14:38:28 +02:00
2014-04-22 20:08:30 +02:00
2014-11-01 13:28:14 +01:00
2015-03-29 03:34:23 +02:00
2014-02-07 19:32:16 +00:00
2014-04-05 03:32:11 +02:00
2015-06-19 11:25:52 +02:00
2010-05-25 14:23:48 +00:00
2015-11-26 01:38:17 +01:00
2014-12-20 10:51:40 +01:00
2014-05-31 13:41:10 +02:00
2014-01-02 22:07:09 +01:00
2014-12-20 10:51:41 +01:00
2012-06-29 20:43:30 +02:00
2015-01-13 00:16:40 +01:00
2015-02-13 20:48:09 +01:00
2015-11-26 01:38:17 +01:00
2014-11-01 13:28:14 +01:00
2015-12-06 12:40:49 +01:00
2015-03-29 03:34:21 +02:00
2015-08-20 14:38:28 +02:00
2014-10-04 23:52:29 +02:00
2015-06-01 23:25:20 +02:00