getservices.cpp: -fix dont replace not existing channel

This commit is contained in:
Jacek Jendrzej
2014-03-30 19:35:48 +02:00
parent b7604664a4
commit fe7775665a

View File

@@ -425,6 +425,9 @@ void CServiceManager::ParseChannels(xmlNodePtr node, const t_transport_stream_id
int result = allchans.erase(chid);
printf("[getservices]: %s '%s' (sid=0x%x): %s", add ? "replacing" : "removing",
name.c_str(), service_id, result ? "succeded.\n" : "FAILED!\n");
if(!result && remove && add)
add = false;//dont replace not existing channel
}
if(!add) {
node = node->xmlNextNode;