On 11/25/22, Andreas Rheinhardt <andreas.rheinha...@outlook.com> wrote: > Fixes the deadlock reported in ticket #10071. > > Signed-off-by: Andreas Rheinhardt <andreas.rheinha...@outlook.com> > --- > libavcodec/pngdec.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c > index 8080094d65..f1cad26c52 100644 > --- a/libavcodec/pngdec.c > +++ b/libavcodec/pngdec.c > @@ -1362,8 +1362,10 @@ exit_loop: > return 0; > } > > - if (percent_missing(s) > avctx->discard_damaged_percentage) > - return AVERROR_INVALIDDATA; > + if (percent_missing(s) > avctx->discard_damaged_percentage) { > + ret = AVERROR_INVALIDDATA; > + goto fail; > + } > > if (s->bits_per_pixel <= 4) > handle_small_bpp(s, p); > -- > 2.34.1 >
ok > _______________________________________________ > 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". > _______________________________________________ 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".