mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avfilter/vf_thumbnail: fix possible crash on error
This commit is contained in:
parent
32bc0e0444
commit
e63a66416f
@ -162,7 +162,7 @@ static av_cold void uninit(AVFilterContext *ctx)
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
ThumbContext *s = ctx->priv;
|
ThumbContext *s = ctx->priv;
|
||||||
for (i = 0; i < s->n_frames && s->frames[i].buf; i++)
|
for (i = 0; i < s->n_frames && s->frames && s->frames[i].buf; i++)
|
||||||
av_frame_free(&s->frames[i].buf);
|
av_frame_free(&s->frames[i].buf);
|
||||||
av_freep(&s->frames);
|
av_freep(&s->frames);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user