diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-06-12 13:39:16 +0100 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-06-12 17:02:48 +0100 |
commit | 8a78ae2d2101622fd244b99178d8bc61175c878e (patch) | |
tree | 5cbc5cd568923eb625ef7d2fbf186ef2ba949473 /libavformat/segment.c | |
parent | b7a4127a45b780d76e6b09427a3d0197c4bc1cdb (diff) | |
download | ffmpeg-8a78ae2d2101622fd244b99178d8bc61175c878e.tar.gz |
segment: Check open_null_ctx() return value
Reported-By: infer
Diffstat (limited to 'libavformat/segment.c')
-rw-r--r-- | libavformat/segment.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/segment.c b/libavformat/segment.c index 55ba6569f2..3479134ec8 100644 --- a/libavformat/segment.c +++ b/libavformat/segment.c @@ -351,7 +351,8 @@ static int seg_write_trailer(struct AVFormatContext *s) if (!seg->write_header_trailer) { if ((ret = segment_end(oc, 0)) < 0) goto fail; - open_null_ctx(&oc->pb); + if ((ret = open_null_ctx(&oc->pb)) < 0) + goto fail; ret = av_write_trailer(oc); close_null_ctx(oc->pb); } else { |