mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 09:21:18 +02:00
getservices: don't update channels if only scrambling changed
This commit is contained in:
committed by
svenhoefer
parent
e810bfe30b
commit
5ca3ccaa5d
@@ -1103,7 +1103,11 @@ bool CServiceManager::CopyCurrentServices(transponder_id_t tpid)
|
|||||||
updated = true;
|
updated = true;
|
||||||
printf("CServiceManager::CopyCurrentServices: [%s] add\n", cI->second.getName().c_str());
|
printf("CServiceManager::CopyCurrentServices: [%s] add\n", cI->second.getName().c_str());
|
||||||
} else {
|
} else {
|
||||||
if(cI->second.scrambled != aI->second.scrambled || cI->second.getName() != aI->second.getName()) {
|
if (cI->second.getName() != aI->second.getName()
|
||||||
|
#ifdef UPDATE_CHANNELS_ON_SCRAMBLED_CHANGE
|
||||||
|
|| cI->second.scrambled != aI->second.scrambled
|
||||||
|
#endif
|
||||||
|
) {
|
||||||
aI->second.setName(cI->second.getName());
|
aI->second.setName(cI->second.getName());
|
||||||
aI->second.scrambled = cI->second.scrambled;
|
aI->second.scrambled = cI->second.scrambled;
|
||||||
aI->second.flags = CZapitChannel::UPDATED;
|
aI->second.flags = CZapitChannel::UPDATED;
|
||||||
@@ -1211,7 +1215,11 @@ bool CServiceManager::SaveCurrentServices(transponder_id_t tpid)
|
|||||||
if(ccI == allchans.end()) {
|
if(ccI == allchans.end()) {
|
||||||
WriteCurrentService(fd, satfound, tpdone, updated, satstr, tI->second, cI->second, "add");
|
WriteCurrentService(fd, satfound, tpdone, updated, satstr, tI->second, cI->second, "add");
|
||||||
} else {
|
} else {
|
||||||
if(strcmp(cI->second.getRealname().c_str(), ccI->second.getRealname().c_str()) || cI->second.scrambled != ccI->second.scrambled) {
|
if (strcmp(cI->second.getRealname().c_str(), ccI->second.getRealname().c_str())
|
||||||
|
#ifdef UPDATE_CHANNELS_ON_SCRAMBLED_CHANGE
|
||||||
|
|| cI->second.scrambled != ccI->second.scrambled
|
||||||
|
#endif
|
||||||
|
) {
|
||||||
cI->second.number = ccI->second.number;
|
cI->second.number = ccI->second.number;
|
||||||
WriteCurrentService(fd, satfound, tpdone, updated, satstr, tI->second, cI->second, "replace");
|
WriteCurrentService(fd, satfound, tpdone, updated, satstr, tI->second, cI->second, "replace");
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user