mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-27 15:32:52 +02:00
upnp: fix url handling when server provides absolute urls
This happens with Jellyfin and possibly other DLNA servers.
Origin commit data
------------------
Branch: ni/coolstream
Commit: b9ac29018d
Author: Hendi <hendi48@freenet.de>
Date: 2023-07-05 (Wed, 05 Jul 2023)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -317,6 +317,8 @@ CUPnPDevice::CUPnPDevice(std::string url)
|
|||||||
eurl=urlbase + "/";
|
eurl=urlbase + "/";
|
||||||
else if (p[0]=='/')
|
else if (p[0]=='/')
|
||||||
eurl=urlbase + std::string(p);
|
eurl=urlbase + std::string(p);
|
||||||
|
else if (!strncmp(p, "http", 4))
|
||||||
|
eurl=std::string(p);
|
||||||
else
|
else
|
||||||
eurl=urlbase + "/" + std::string(p);
|
eurl=urlbase + "/" + std::string(p);
|
||||||
founde = true;
|
founde = true;
|
||||||
@@ -328,6 +330,8 @@ CUPnPDevice::CUPnPDevice(std::string url)
|
|||||||
curl=urlbase + "/";
|
curl=urlbase + "/";
|
||||||
else if (p[0]=='/')
|
else if (p[0]=='/')
|
||||||
curl=urlbase + std::string(p);
|
curl=urlbase + std::string(p);
|
||||||
|
else if (!strncmp(p, "http", 4))
|
||||||
|
curl=std::string(p);
|
||||||
else
|
else
|
||||||
curl=urlbase + "/" + std::string(p);
|
curl=urlbase + "/" + std::string(p);
|
||||||
foundc = true;
|
foundc = true;
|
||||||
|
Reference in New Issue
Block a user