summaryrefslogtreecommitdiffstats
path: root/libavfilter/lavfutils.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-10-17 19:55:13 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-10-17 20:00:20 +0200
commitfd9e88fe6018bc72cd0aa10afc3c1a68df8c6558 (patch)
treef8db5ba8c080a9db9fd3f7236c5c0d559253782a /libavfilter/lavfutils.c
parenta4fe661157b22a353ecce51f5c717c42c8fe00b0 (diff)
downloadffmpeg-streaming-fd9e88fe6018bc72cd0aa10afc3c1a68df8c6558.zip
ffmpeg-streaming-fd9e88fe6018bc72cd0aa10afc3c1a68df8c6558.tar.gz
libavfilter/lavfutils: remove useless NULL check on codec context
The code would crash before if it was NULL Fixes CID733804 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavfilter/lavfutils.c')
-rw-r--r--libavfilter/lavfutils.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libavfilter/lavfutils.c b/libavfilter/lavfutils.c
index a4711f9..62cf167 100644
--- a/libavfilter/lavfutils.c
+++ b/libavfilter/lavfutils.c
@@ -85,8 +85,7 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
av_image_copy(data, linesize, (const uint8_t **)frame->data, frame->linesize, *pix_fmt, *w, *h);
end:
- if (codec_ctx)
- avcodec_close(codec_ctx);
+ avcodec_close(codec_ctx);
if (format_ctx)
avformat_close_input(&format_ctx);
av_freep(&frame);
OpenPOWER on IntegriCloud