diff --git a/packages/mediacenter/xbmc-pvr-addons/meta b/packages/mediacenter/xbmc-pvr-addons/meta index 0f684d9b2e..eb21f6ff80 100644 --- a/packages/mediacenter/xbmc-pvr-addons/meta +++ b/packages/mediacenter/xbmc-pvr-addons/meta @@ -19,7 +19,7 @@ ################################################################################ PKG_NAME="xbmc-pvr-addons" -PKG_VERSION="frodo-78b0aae" +PKG_VERSION="frodo-910d7e7" if [ "$XBMC" = "master" ]; then PKG_VERSION="b84a88f" fi diff --git a/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-01-PR200.patch b/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-01-PR200.patch deleted file mode 100644 index 97bd56c995..0000000000 Binary files a/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-01-PR200.patch and /dev/null differ diff --git a/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-02-PR200-update.patch b/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-02-PR200-update.patch deleted file mode 100644 index f74cbb0ebc..0000000000 --- a/packages/mediacenter/xbmc-pvr-addons/patches/frodo-78b0aae/xbmc-pvr-addons-frodo-02-PR200-update.patch +++ /dev/null @@ -1,345 +0,0 @@ -commit f014d5dcc803d705355148efe2ec720217880d0a -Author: Stefan Saraev -Date: Mon Jul 1 19:57:33 2013 +0300 - - backport latest changes - - added latest changes up to https://github.com/afedchin/xbmc-addon-iptvsimple/commit/a716cdc3cdf44 - - all credit goes to Anton Fedchin - -diff --git a/addons/pvr.iptvsimple/addon/addon.xml.in b/addons/pvr.iptvsimple/addon/addon.xml.in -index 185c3ab..d4692f8 100644 ---- a/addons/pvr.iptvsimple/addon/addon.xml.in -+++ b/addons/pvr.iptvsimple/addon/addon.xml.in -@@ -6,7 +6,7 @@ - provider-name="nightik"> - - -- -+ - - - -- -- -- -- -+ -+ -+ -+ -+ -+ -+ -+ - -- -- -- -- -- -- --> -- -+ -+ -+ -+ -+ -+ -+ -+ --> -+ -+ - -- -- -+ -+ -+ -+ -+ - -diff --git a/addons/pvr.iptvsimple/src/PVRIptvData.cpp b/addons/pvr.iptvsimple/src/PVRIptvData.cpp -index 4ca5265..24e3cee 100644 ---- a/addons/pvr.iptvsimple/src/PVRIptvData.cpp -+++ b/addons/pvr.iptvsimple/src/PVRIptvData.cpp -@@ -155,16 +155,20 @@ bool PVRIptvData::LoadEPG(time_t iStart, time_t iEnd) - if (buffer[0] != '\x3C' || buffer[1] != '\x3F' || buffer[2] != '\x78' || - buffer[3] != '\x6D' || buffer[4] != '\x6C') - { -- // check for tar archive -- if (strcmp(buffer + 0x101, "ustar") || strcmp(buffer + 0x101, "GNUtar")) -+ // check for BOM -+ if (buffer[0] != '\xEF' || buffer[1] != '\xBB' || buffer[2] != '\xBF') - { -- buffer += 0x200; // RECORDSIZE = 512 -- } -- else -- { -- XBMC->Log(LOG_ERROR, "Invalid EPG file '%s': unable to decompress file.", m_strXMLTVUrl.c_str()); -- m_bEGPLoaded = true; -- return false; -+ // check for tar archive -+ if (strcmp(buffer + 0x101, "ustar") || strcmp(buffer + 0x101, "GNUtar")) -+ { -+ buffer += 0x200; // RECORDSIZE = 512 -+ } -+ else -+ { -+ XBMC->Log(LOG_ERROR, "Invalid EPG file '%s': unable to parse file.", m_strXMLTVUrl.c_str()); -+ m_bEGPLoaded = true; -+ return false; -+ } - } - } - -@@ -321,10 +325,10 @@ bool PVRIptvData::LoadPlayList(void) - /* load channels */ - bool bFirst = true; - -- int iUniqueChannelId = 0; -+ int iChannelIndex = 0; - int iUniqueGroupId = 0; - int iCurrentGroupId = 0; -- int iChannelNum = 0; -+ int iChannelNum = g_iStartNumber; - int iEPGTimeShift = 0; - - PVRIptvChannel tmpChannel; -@@ -446,8 +450,8 @@ bool PVRIptvData::LoadPlayList(void) - else if (strLine[0] != '#') - { - PVRIptvChannel channel; -- channel.iUniqueId = ++iUniqueChannelId; -- channel.iChannelNumber = ++iChannelNum; -+ channel.iUniqueId = GetChannelId(tmpChannel.strChannelName.c_str(), strLine); -+ channel.iChannelNumber = iChannelNum++; - channel.strTvgId = tmpChannel.strTvgId; - channel.strChannelName = tmpChannel.strChannelName; - channel.strTvgName = tmpChannel.strTvgName; -@@ -460,10 +464,11 @@ bool PVRIptvData::LoadPlayList(void) - if (iCurrentGroupId > 0) - { - channel.bRadio = m_groups.at(iCurrentGroupId - 1).bRadio; -- m_groups.at(iCurrentGroupId - 1).members.push_back(channel.iChannelNumber); -+ m_groups.at(iCurrentGroupId - 1).members.push_back(iChannelIndex); - } - - m_channels.push_back(channel); -+ iChannelIndex++; - - tmpChannel.strTvgId = ""; - tmpChannel.strChannelName = ""; -@@ -568,26 +573,24 @@ PVR_ERROR PVRIptvData::GetChannelGroups(ADDON_HANDLE handle, bool bRadio) - - PVR_ERROR PVRIptvData::GetChannelGroupMembers(ADDON_HANDLE handle, const PVR_CHANNEL_GROUP &group) - { -- for (unsigned int iGroupPtr = 0; iGroupPtr < m_groups.size(); iGroupPtr++) -+ PVRIptvChannelGroup *myGroup; -+ if ((myGroup = FindGroup(group.strGroupName)) != NULL) - { -- PVRIptvChannelGroup &myGroup = m_groups.at(iGroupPtr); -- if (!strcmp(myGroup.strGroupName.c_str(),group.strGroupName)) -+ for (unsigned int iPtr = 0; iPtr < myGroup->members.size(); iPtr++) - { -- for (unsigned int iChannelPtr = 0; iChannelPtr < myGroup.members.size(); iChannelPtr++) -- { -- int iId = myGroup.members.at(iChannelPtr) - 1; -- if (iId < 0 || iId > (int)m_channels.size() - 1) -- continue; -- PVRIptvChannel &channel = m_channels.at(iId); -- PVR_CHANNEL_GROUP_MEMBER xbmcGroupMember; -- memset(&xbmcGroupMember, 0, sizeof(PVR_CHANNEL_GROUP_MEMBER)); -- -- strncpy(xbmcGroupMember.strGroupName, group.strGroupName, sizeof(xbmcGroupMember.strGroupName) - 1); -- xbmcGroupMember.iChannelUniqueId = channel.iUniqueId; -- xbmcGroupMember.iChannelNumber = channel.iChannelNumber; -- -- PVR->TransferChannelGroupMember(handle, &xbmcGroupMember); -- } -+ int iIndex = myGroup->members.at(iPtr); -+ if (iIndex < 0 || iIndex >= (int) m_channels.size()) -+ continue; -+ -+ PVRIptvChannel &channel = m_channels.at(iIndex); -+ PVR_CHANNEL_GROUP_MEMBER xbmcGroupMember; -+ memset(&xbmcGroupMember, 0, sizeof(PVR_CHANNEL_GROUP_MEMBER)); -+ -+ strncpy(xbmcGroupMember.strGroupName, group.strGroupName, sizeof(xbmcGroupMember.strGroupName) - 1); -+ xbmcGroupMember.iChannelUniqueId = channel.iUniqueId; -+ xbmcGroupMember.iChannelNumber = channel.iChannelNumber; -+ -+ PVR->TransferChannelGroupMember(handle, &xbmcGroupMember); - } - } - -@@ -891,9 +894,7 @@ int PVRIptvData::GetCachedFileContents(const std::string &strCachedName, const s - void PVRIptvData::ApplyChannelsLogos() - { - if (m_strLogoPath.IsEmpty()) -- { - return; -- } - - vector::iterator channel; - for(channel = m_channels.begin(); channel < m_channels.end(); channel++) -@@ -975,3 +976,17 @@ CStdString PVRIptvData::ReadMarkerValue(std::string &strLine, const char* strMar - - return std::string(""); - } -+ -+int PVRIptvData::GetChannelId(const char * strChannelName, const char * strStreamUrl) -+{ -+ std::string concat(strChannelName); -+ concat.append(strStreamUrl); -+ -+ const char* strString = concat.c_str(); -+ int iId = 0; -+ int c; -+ while (c = *strString++) -+ iId = ((iId << 5) + iId) + c; /* iId * 33 + c */ -+ -+ return abs(iId); -+} -\ No newline at end of file -diff --git a/addons/pvr.iptvsimple/src/PVRIptvData.h b/addons/pvr.iptvsimple/src/PVRIptvData.h -index 944a734..c49b0cc 100644 ---- a/addons/pvr.iptvsimple/src/PVRIptvData.h -+++ b/addons/pvr.iptvsimple/src/PVRIptvData.h -@@ -103,6 +103,7 @@ protected: - virtual int GetCachedFileContents(const std::string &strCachedName, const std::string &strFilePath, std::string &strContent); - virtual void ApplyChannelsLogos(); - virtual CStdString ReadMarkerValue(std::string &strLine, const char * strMarkerName); -+ virtual int GetChannelId(const char * strChannelName, const char * strStreamUrl); - - protected: - virtual void *Process(void); -diff --git a/addons/pvr.iptvsimple/src/client.cpp b/addons/pvr.iptvsimple/src/client.cpp -index b80f483..b8c55b4 100644 ---- a/addons/pvr.iptvsimple/src/client.cpp -+++ b/addons/pvr.iptvsimple/src/client.cpp -@@ -54,6 +54,7 @@ std::string g_strTvgPath = ""; - std::string g_strM3UPath = ""; - std::string g_strLogoPath = ""; - int g_iEPGTimeShift = 0; -+int g_iStartNumber = 1; - bool g_bTSOverride = true; - - extern std::string PathCombine(const std::string &strPath, const std::string &strFileName) -@@ -102,7 +103,10 @@ void ADDON_ReadSettings(void) - { - g_strM3UPath = GetClientFilePath(M3U_FILE_NAME); - } -- -+ if (!XBMC->GetSetting("startNum", &g_iStartNumber)) -+ { -+ g_iStartNumber = 1; -+ } - if (!XBMC->GetSetting("epgPathType", &iPathType)) - { - iPathType = 1; -diff --git a/addons/pvr.iptvsimple/src/client.h b/addons/pvr.iptvsimple/src/client.h -index bc81eeb..89500f1 100644 ---- a/addons/pvr.iptvsimple/src/client.h -+++ b/addons/pvr.iptvsimple/src/client.h -@@ -27,7 +27,7 @@ - #include "libXBMC_pvr.h" - #include "libXBMC_gui.h" - --#define PVR_CLIENT_VERSION "0.1.3" -+#define PVR_CLIENT_VERSION "1.8.1" - #define M3U_FILE_NAME "iptv.m3u.cache" - #define TVG_FILE_NAME "xmltv.xml.cache" - -@@ -47,6 +47,7 @@ extern std::string g_strM3UPath; - extern std::string g_strTvgPath; - extern std::string g_strLogoPath; - extern int g_iEPGTimeShift; -+extern int g_iStartNumber; - extern bool g_bTSOverride; - - extern std::string PathCombine(const std::string &strPath, const std::string &strFileName);