summaryrefslogtreecommitdiff
path: root/libavformat/hdsenc.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-01-09 15:54:15 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-01-09 15:55:07 +0100
commitb1d223301f03741c87a0e0b755c108bbc2eafc93 (patch)
tree28074e898454e19044287de8dc388473ede48f5e /libavformat/hdsenc.c
parent04091552616e6c5bea754ebbee26f77cb8ba416e (diff)
downloadffmpeg-b1d223301f03741c87a0e0b755c108bbc2eafc93.tar.gz
avformat/hdsenc: Remove redundant NULL pointer checks
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/hdsenc.c')
-rw-r--r--libavformat/hdsenc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/libavformat/hdsenc.c b/libavformat/hdsenc.c
index 40520283f9..48810a9a34 100644
--- a/libavformat/hdsenc.c
+++ b/libavformat/hdsenc.c
@@ -139,11 +139,10 @@ static void hds_free(AVFormatContext *s)
return;
for (i = 0; i < s->nb_streams; i++) {
OutputStream *os = &c->streams[i];
- if (os->out)
- avio_closep(&os->out);
+ avio_closep(&os->out);
if (os->ctx && os->ctx_inited)
av_write_trailer(os->ctx);
- if (os->ctx && os->ctx->pb)
+ if (os->ctx)
av_freep(&os->ctx->pb);
if (os->ctx)
avformat_free_context(os->ctx);