[FFmpeg-cvslog] avformat/dashenc: fix for segment open issue when persistent connection is enabled

Vishwanath Dixit git at videolan.org
Sat Mar 3 15:18:47 EET 2018


ffmpeg | branch: master | Vishwanath Dixit <vdixit at akamai.com> | Fri Mar  2 12:10:37 2018 +0530| [0dd1fff1c97d6d4e4f9c485028652aa791e4a91f] | committer: Karthick Jeyapal

avformat/dashenc: fix for segment open issue when persistent connection is enabled

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

 libavformat/dashenc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/dashenc.c b/libavformat/dashenc.c
index 83e0cff728..489e458147 100644
--- a/libavformat/dashenc.c
+++ b/libavformat/dashenc.c
@@ -1308,7 +1308,7 @@ static int dash_write_packet(AVFormatContext *s, AVPacket *pkt)
         flush_init_segment(s, os);
 
     //open the output context when the first frame of a segment is ready
-    if (!c->single_file && !os->out) {
+    if (!c->single_file && os->packets_written == 1) {
         AVDictionary *opts = NULL;
         const char *proto = avio_find_protocol_name(s->url);
         int use_rename = proto && !strcmp(proto, "file");



More information about the ffmpeg-cvslog mailing list