On 11/25/22, Andreas Rheinhardt <[email protected]> wrote: > Fixes the deadlock reported in ticket #10071. > > Signed-off-by: Andreas Rheinhardt <[email protected]> > --- > 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 > [email protected] > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > [email protected] with subject "unsubscribe". > _______________________________________________ ffmpeg-devel mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
