avcodec/pngdec: print the actual number of bytes left in the error case

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-09-11 16:15:02 +02:00
parent de4a4ca1a0
commit a6153bde3d
1 changed files with 1 additions and 1 deletions

View File

@ -559,7 +559,7 @@ static int decode_frame(AVCodecContext *avctx,
} }
for (;;) { for (;;) {
if (bytestream2_get_bytes_left(&s->gb) <= 0) { if (bytestream2_get_bytes_left(&s->gb) <= 0) {
av_log(avctx, AV_LOG_ERROR, "No bytes left\n"); av_log(avctx, AV_LOG_ERROR, "%d bytes left\n", bytestream2_get_bytes_left(&s->gb));
if ( s->state & PNG_ALLIMAGE if ( s->state & PNG_ALLIMAGE
&& avctx->strict_std_compliance <= FF_COMPLIANCE_NORMAL) && avctx->strict_std_compliance <= FF_COMPLIANCE_NORMAL)
goto exit_loop; goto exit_loop;