mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-31 01:11:06 +02:00
audioplayer: allow to add https:// urls from playlist
Origin commit data
------------------
Branch: ni/coolstream
Commit: 573ced1134
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2017-09-25 (Mon, 25 Sep 2017)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
committed by
vanhofen
parent
ad648129bf
commit
6b041221cc
@@ -4,6 +4,7 @@
|
||||
Copyright (C) 2001 Steffen Hehn 'McClean'
|
||||
Copyright (C) 2002-2008 the tuxbox project contributors
|
||||
Copyright (C) 2008 Novell, Inc. Author: Stefan Seyfried
|
||||
Copyright (C) 2011-2013,2015,2017 Stefan Seyfried
|
||||
Copyright (C) 2017 Sven Hoefer
|
||||
|
||||
License: GPL
|
||||
@@ -1169,9 +1170,13 @@ void CAudioPlayerGui::processPlaylistUrl(const char *url, const char *name, cons
|
||||
if (line[0] != '#')
|
||||
{
|
||||
//printf("chunk: line = %s\n", line);
|
||||
ptr = strstr(line, "http://");
|
||||
if (ptr != NULL)
|
||||
{
|
||||
const char *schemes[] = {"http://", "https://", NULL };
|
||||
const char **scheme = schemes;
|
||||
while (*scheme) {
|
||||
ptr = strstr(line, *scheme);
|
||||
scheme++;
|
||||
if (ptr == NULL)
|
||||
continue;
|
||||
char *tmp;
|
||||
// strip \n and \r characters from url
|
||||
tmp = strchr(line, '\r');
|
||||
@@ -1181,6 +1186,7 @@ void CAudioPlayerGui::processPlaylistUrl(const char *url, const char *name, cons
|
||||
if (tmp != NULL)
|
||||
*tmp = '\0';
|
||||
addUrl2Playlist(ptr, name, logo, tim);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user