mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-03-02 02:30:58 +00:00
avcodec/qdrw: consume bytes when end is reached for 8bpp case
This should really be part of previous commit. Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
1dcf91f2d3
commit
3a7f8d2a1f
@ -242,8 +242,9 @@ static int decode_rle(AVCodecContext *avctx, AVFrame *p, GetByteContext *gbc,
|
|||||||
left -= 2;
|
left -= 2;
|
||||||
} else { /* copy */
|
} else { /* copy */
|
||||||
for (j = 0; j < code + 1; j++) {
|
for (j = 0; j < code + 1; j++) {
|
||||||
|
pix = bytestream2_get_byte(gbc);
|
||||||
if (pos < offset)
|
if (pos < offset)
|
||||||
out[pos] = bytestream2_get_byte(gbc);
|
out[pos] = pix;
|
||||||
pos += step;
|
pos += step;
|
||||||
if (pos >= offset && step > 1) {
|
if (pos >= offset && step > 1) {
|
||||||
pos -= offset;
|
pos -= offset;
|
||||||
|
Loading…
Reference in New Issue
Block a user