[FFmpeg-cvslog] avformat/segment: Fix header_filename handling

Michael Niedermayer git at videolan.org
Wed Feb 10 18:15:16 CET 2016


ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Wed Feb 10 17:59:58 2016 +0100| [21b459e4bbfc14fd1ec9076e3a0b01f6f11ba960] | committer: Michael Niedermayer

avformat/segment: Fix header_filename handling

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=21b459e4bbfc14fd1ec9076e3a0b01f6f11ba960
---

 libavformat/segment.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/libavformat/segment.c b/libavformat/segment.c
index f6df175..dd3b092 100644
--- a/libavformat/segment.c
+++ b/libavformat/segment.c
@@ -701,7 +701,9 @@ static int seg_write_header(AVFormatContext *s)
         goto fail;
 
     if (seg->write_header_trailer) {
-        if ((ret = s->io_open(s, &oc->pb, oc->filename, AVIO_FLAG_WRITE, NULL)) < 0) {
+        if ((ret = s->io_open(s, &oc->pb,
+                              seg->header_filename ? seg->header_filename : oc->filename,
+                              AVIO_FLAG_WRITE, NULL)) < 0) {
             av_log(s, AV_LOG_ERROR, "Failed to open segment '%s'\n", oc->filename);
             goto fail;
         }



More information about the ffmpeg-cvslog mailing list