Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix m3u parsing for extended #EXTM3U header
Some .m3u files have extendend parameters. For example:

`#EXTM3U url-tvg="http://xxx/" m3uautoload=1 cache=500 deinterlace=1`

Compare only the first 7 chars to allow this kind of headers.

Fixes `iptv: unknown playlist format for network ''` when the file is valid.
  • Loading branch information
fedux authored and perexg committed Dec 6, 2016
1 parent 1dd2652 commit 03f90fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/misc/m3u.c
Expand Up @@ -130,7 +130,7 @@ htsmsg_t *parse_m3u
while (*data && *data <= ' ') data++;
p = data;
data = until_eol(data);
if (strcmp(p, "#EXTM3U")) {
if (strncmp(p, "#EXTM3U", 7)) {
htsmsg_add_msg(m, "items", htsmsg_create_list());
return m;
}
Expand Down

0 comments on commit 03f90fc

Please sign in to comment.