mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-27 07:22:57 +02:00
controlapi: minor changes in url creation in xmltvm3uCGI() function
Origin commit data
------------------
Branch: ni/coolstream
Commit: d5c3c9a963
Author: vanhofen <vanhofen@gmx.de>
Date: 2018-09-09 (Sun, 09 Sep 2018)
Origin message was:
------------------
- controlapi: minor changes in url creation in xmltvm3uCGI() function
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -3310,14 +3310,15 @@ void CControlAPI::xmltvm3uCGI(CyhookHandler *hh)
|
||||
std::string result = "";
|
||||
|
||||
int mode = NeutrinoAPI->Zapit->getMode();
|
||||
// build url
|
||||
std::string url = "";
|
||||
if (!hh->ParamList["host"].empty())
|
||||
url = "http://" + hh->ParamList["host"];
|
||||
else
|
||||
url = "http://" + hh->HeaderList["Host"];
|
||||
|
||||
std::string lurl = url;
|
||||
std::string host = "";
|
||||
if (!hh->ParamList["host"].empty())
|
||||
host = "http://" + hh->ParamList["host"];
|
||||
else
|
||||
host = "http://" + hh->HeaderList["Host"];
|
||||
|
||||
// build url
|
||||
std::string url = host;
|
||||
/* strip off optional custom port */
|
||||
if (url.rfind(":") != 4)
|
||||
url = url.substr(0, url.rfind(":"));
|
||||
@@ -3340,7 +3341,7 @@ void CControlAPI::xmltvm3uCGI(CyhookHandler *hh)
|
||||
CZapitChannel *channel = chanlist[j];
|
||||
std::string bouq_name = g_bouquetManager->Bouquets[i]->bName;
|
||||
std::string chan_id_short = string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID() & 0xFFFFFFFFFFFFULL);
|
||||
result += "#EXTINF:-1 tvg-id=\"" + chan_id_short + "\" tvg-logo=\"" + lurl + NeutrinoAPI->getLogoFile(channel->getChannelID()) + "\" group-title=\"" + bouq_name + "\"," + channel->getName() + "\n";
|
||||
result += "#EXTINF:-1 tvg-id=\"" + chan_id_short + "\" tvg-logo=\"" + host + NeutrinoAPI->getLogoFile(channel->getChannelID()) + "\" group-title=\"" + bouq_name + "\"," + channel->getName() + "\n";
|
||||
result += url + string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID()) + "\n";
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user