Merge commit '344f7b5a7e0d50573dec402dfe6228676f3889d9'
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 30 Apr 2014 18:02:42 +0000 (20:02 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 30 Apr 2014 18:03:06 +0000 (20:03 +0200)
* commit '344f7b5a7e0d50573dec402dfe6228676f3889d9':
  hls: Report the current media sequence

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavformat/hlsenc.c

@@@ -146,10 -145,13 +146,13 @@@ static int hls_window(AVFormatContext *
      avio_printf(hls->pb, "#EXT-X-VERSION:3\n");
      avio_printf(hls->pb, "#EXT-X-TARGETDURATION:%d\n", target_duration);
      avio_printf(hls->pb, "#EXT-X-MEDIA-SEQUENCE:%"PRId64"\n",
 -                FFMAX(0, hls->sequence - hls->size));
 +                FFMAX(0, hls->sequence - hls->nb_entries));
  
+     av_log(s, AV_LOG_VERBOSE, "EXT-X-MEDIA-SEQUENCE:%"PRId64"\n",
+            FFMAX(0, hls->sequence - hls->size));
      for (en = hls->list; en; en = en->next) {
 -        avio_printf(hls->pb, "#EXTINF:%d,\n", en->duration);
 +        avio_printf(hls->pb, "#EXTINF:%f,\n", en->duration);
          if (hls->baseurl)
              avio_printf(hls->pb, "%s", hls->baseurl);
          avio_printf(hls->pb, "%s\n", en->name);