On 12/10/2019 6:59 PM, Andreas Rheinhardt wrote: > When an incomplete header is encountered, apng_read_header would under > certain circumstances only return the return value of the last > successfull call. So override this by returning AVERROR_EOF manually. > > Signed-off-by: Andreas Rheinhardt <andreas.rheinha...@gmail.com> > --- > libavformat/apngdec.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/libavformat/apngdec.c b/libavformat/apngdec.c > index 0f1d04a365..6c58fd9d04 100644 > --- a/libavformat/apngdec.c > +++ b/libavformat/apngdec.c > @@ -240,6 +240,8 @@ static int apng_read_header(AVFormatContext *s) > } > } > > + return AVERROR_EOF;
An incomplete header is invalid/truncated data, so this should be either AVERROR_INVALIDDATA or AVERROR(EIO). > + > fail: > return ret; > } > _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".