[vlc-commits] HLS: PROGRAM-ID is not mandatory in EXT-X-STREAM-INF

Jean-Baptiste Kempf git at videolan.org
Tue Oct 9 14:51:04 CEST 2012


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Tue Oct  9 14:50:30 2012 +0200| [6eda4e0c57e0283ceff72631f1408eda38d4fb38] | committer: Jean-Baptiste Kempf

HLS:  PROGRAM-ID is not mandatory in EXT-X-STREAM-INF

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6eda4e0c57e0283ceff72631f1408eda38d4fb38
---

 modules/stream_filter/httplive.c |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/modules/stream_filter/httplive.c b/modules/stream_filter/httplive.c
index c8948b3..d6ee0a9 100644
--- a/modules/stream_filter/httplive.c
+++ b/modules/stream_filter/httplive.c
@@ -653,13 +653,13 @@ static int parse_StreamInformation(stream_t *s, vlc_array_t **hls_stream,
     assert(*hls == NULL);
 
     attr = parse_Attributes(p_read, "PROGRAM-ID");
-    if (attr == NULL)
+    if (attr)
     {
-        msg_Err(s, "#EXT-X-STREAM-INF: expected PROGRAM-ID=<value>");
-        return VLC_EGENERIC;
+        id = atol(attr);
+        free(attr);
     }
-    id = atol(attr);
-    free(attr);
+    else
+        id = 0;
 
     attr = parse_Attributes(p_read, "BANDWIDTH");
     if (attr == NULL)



More information about the vlc-commits mailing list