zapit/src/bouquets.cpp: fix possible crash, if no channel name present in bouquets xml

Origin commit data
------------------
Branch: ni/coolstream
Commit: f8f299eadc
Author: [CST] Focus <focus.cst@gmail.com>
Date: 2014-10-23 (Thu, 23 Oct 2014)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
[CST] Focus
2014-10-23 18:19:28 +04:00
parent 2ee43b999b
commit 041ba8f5f1

View File

@@ -405,7 +405,10 @@ void CBouquetManager::parseBouquetsXml(const char *fname, bool bUser)
newBouquet->bScanEpg = scanepg ? (strcmp(scanepg, "1") == 0) : false;
channel_node = search->xmlChildrenNode;
while ((channel_node = xmlGetNextOccurence(channel_node, "S")) != NULL) {
std::string name2 = xmlGetAttribute(channel_node, "n");
std::string name2;
name = xmlGetAttribute(channel_node, "n");
if (name)
name2 = name;
char *url = xmlGetAttribute(channel_node, "u");
GET_ATTR(channel_node, "i", SCANF_SERVICE_ID_TYPE, service_id);
GET_ATTR(channel_node, "on", SCANF_ORIGINAL_NETWORK_ID_TYPE, original_network_id);