mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
avfilter/vf_signalstats: fix avframe leak on error
Fixes CID1257014 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
8280b7db47
commit
7ad742b224
@ -132,8 +132,10 @@ static AVFrame *alloc_frame(enum AVPixelFormat pixfmt, int w, int h)
|
||||
frame->width = w;
|
||||
frame->height = h;
|
||||
|
||||
if (av_frame_get_buffer(frame, 32) < 0)
|
||||
if (av_frame_get_buffer(frame, 32) < 0) {
|
||||
av_frame_free(&frame);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return frame;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user