[FFmpeg-devel,1/3] avformat/hlsenc: fix the duration of m4s segment is unusually smaller than expected.

Submitted by Charles Liu on Oct. 9, 2018, 9:25 a.m.

Details

Message ID 20181009092523.13912-1-liuchh83@gmail.com
State New
Headers show

Commit Message

Charles Liu Oct. 9, 2018, 9:25 a.m.
In fmp4 mode, the duration of the second m4s segment is unusually smaller than the expected segment time.

Signed-off-by: Charles Liu <liuchh83@gmail.com>
---
 libavformat/hlsenc.c | 4 ----
 1 file changed, 4 deletions(-)

Patch hide | download patch | download mbox

diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c
index 28c2dd62fc..3ccd8756f6 100644
--- a/libavformat/hlsenc.c
+++ b/libavformat/hlsenc.c
@@ -2233,10 +2233,6 @@  static int hls_write_packet(AVFormatContext *s, AVPacket *pkt)
                 }
         }
 
-        if (vs->fmp4_init_mode) {
-            vs->number--;
-        }
-
         if (hls->segment_type == SEGMENT_TYPE_FMP4) {
             if (hls->flags & HLS_SINGLE_FILE) {
                 ret = flush_dynbuf(vs, &range_length);