diff options
author | Anton Khirnov <anton@khirnov.net> | 2012-07-15 11:16:53 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2012-07-22 09:14:05 +0200 |
commit | 1dc42050185d63c1de5d16146fbaee92640af187 (patch) | |
tree | e53dbbfc52894acf4efd526b9ddcaf1d0b87d94d /libavfilter/vf_transpose.c | |
parent | 80e4ed279b3abe9f5356e2b56255b2aa64527345 (diff) | |
download | ffmpeg-1dc42050185d63c1de5d16146fbaee92640af187.tar.gz |
lavfi: check all avfilter_ref_buffer() calls for errors.
Diffstat (limited to 'libavfilter/vf_transpose.c')
-rw-r--r-- | libavfilter/vf_transpose.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libavfilter/vf_transpose.c b/libavfilter/vf_transpose.c index 49b54d760b..90f08e42cd 100644 --- a/libavfilter/vf_transpose.c +++ b/libavfilter/vf_transpose.c @@ -120,6 +120,7 @@ static int config_props_output(AVFilterLink *outlink) static int start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref) { AVFilterLink *outlink = inlink->dst->outputs[0]; + AVFilterBufferRef *buf_out; outlink->out_buf = ff_get_video_buffer(outlink, AV_PERM_WRITE, outlink->w, outlink->h); @@ -135,7 +136,10 @@ static int start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref) outlink->out_buf->video->pixel_aspect.den = picref->video->pixel_aspect.num; } - return ff_start_frame(outlink, avfilter_ref_buffer(outlink->out_buf, ~0)); + buf_out = avfilter_ref_buffer(outlink->out_buf, ~0); + if (!buf_out) + return AVERROR(ENOMEM); + return ff_start_frame(outlink, buf_out); } static int end_frame(AVFilterLink *inlink) |