mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-24 13:56:33 +02:00
avfilter/vf_blend: fix un-checked potential memory allocation failure
Signed-off-by: Wu Jianhua <jianhua.wu@intel.com>
This commit is contained in:
parent
aa8bb05d29
commit
49250b582a
@ -279,7 +279,11 @@ static AVFrame *blend_frame(AVFilterContext *ctx, AVFrame *top_buf,
|
||||
dst_buf = ff_get_video_buffer(outlink, outlink->w, outlink->h);
|
||||
if (!dst_buf)
|
||||
return top_buf;
|
||||
av_frame_copy_props(dst_buf, top_buf);
|
||||
|
||||
if (av_frame_copy_props(dst_buf, top_buf) < 0) {
|
||||
av_frame_free(&dst_buf);
|
||||
return top_buf;
|
||||
}
|
||||
|
||||
for (plane = 0; plane < s->nb_planes; plane++) {
|
||||
int hsub = plane == 1 || plane == 2 ? s->hsub : 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user