diff options
author | Carl Eugen Hoyos <cehoyos@ag.or.at> | 2014-03-11 09:56:38 +0100 |
---|---|---|
committer | Carl Eugen Hoyos <cehoyos@ag.or.at> | 2014-03-11 09:56:38 +0100 |
commit | 666749f6694510764253ed5602ed5d1cdcfb243f (patch) | |
tree | 9113cda77334db79de52f6e98c4e94bde1f21d19 /libavcodec/pngdec.c | |
parent | e161c1bbfce904cd8e6683c4eeaadb634dd4c8e7 (diff) | |
download | ffmpeg-666749f6694510764253ed5602ed5d1cdcfb243f.tar.gz |
Decode png images without iend chunk.
Fixes ticket #3357.
Diffstat (limited to 'libavcodec/pngdec.c')
-rw-r--r-- | libavcodec/pngdec.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c index 516dd41f0c..985517d88d 100644 --- a/libavcodec/pngdec.c +++ b/libavcodec/pngdec.c @@ -546,6 +546,9 @@ static int decode_frame(AVCodecContext *avctx, for (;;) { if (bytestream2_get_bytes_left(&s->gb) <= 0) { av_log(avctx, AV_LOG_ERROR, "No bytes left\n"); + if ( s->state & PNG_ALLIMAGE + && avctx->strict_std_compliance <= FF_COMPLIANCE_NORMAL) + goto exit_loop; goto fail; } |