Skip to content

Commit

Permalink
avfilter/vf_thumbnail: fix possible crash on error
Browse files Browse the repository at this point in the history
  • Loading branch information
richardpl committed Feb 10, 2020
1 parent 32bc0e0 commit e63a664
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libavfilter/vf_thumbnail.c
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ static av_cold void uninit(AVFilterContext *ctx)
{
int i;
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_freep(&s->frames);
}
Expand Down

0 comments on commit e63a664

Please sign in to comment.