0 means no data consumed, so it can trigger an infinite loop in the
caller.
CC:libav-stable@libav.org
(cherry picked from commit c7d9b473e28238d4a4ef1b7e8b42c1cca256da36)
Conflicts:
libavcodec/cdgraphics.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
... | ... |
@@ -361,11 +361,10 @@ static int cdg_decode_frame(AVCodecContext *avctx, |
361 | 361 |
*got_frame = 1; |
362 | 362 |
} else { |
363 | 363 |
*got_frame = 0; |
364 |
- buf_size = 0; |
|
365 | 364 |
} |
366 | 365 |
|
367 | 366 |
*(AVFrame *) data = cc->frame; |
368 |
- return buf_size; |
|
367 |
+ return avpkt->size; |
|
369 | 368 |
} |
370 | 369 |
|
371 | 370 |
static av_cold int cdg_decode_end(AVCodecContext *avctx) |