mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-01 09:51:13 +02:00
fix sort freq with negative satellite position
Origin commit data
------------------
Commit: 7b356ad58f
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2014-12-24 (Wed, 24 Dec 2014)
This commit is contained in:
@@ -315,7 +315,7 @@ struct CmpChannelByFreq: public std::binary_function <const CZapitChannel * cons
|
|||||||
if((c1->getTransponderId() == c2->getTransponderId()) && ((uint64_t)c1->getFreqId() <<32 | c1->polarization <<16 | c1->getSatellitePosition()) == ((uint64_t)c2->getFreqId()<<32 | c2->polarization <<16| c2->getSatellitePosition()))
|
if((c1->getTransponderId() == c2->getTransponderId()) && ((uint64_t)c1->getFreqId() <<32 | c1->polarization <<16 | c1->getSatellitePosition()) == ((uint64_t)c2->getFreqId()<<32 | c2->polarization <<16| c2->getSatellitePosition()))
|
||||||
return std::lexicographical_compare(c1->getName().begin(), c1->getName().end(), c2->getName().begin(), c2->getName().end(), comparetolower);
|
return std::lexicographical_compare(c1->getName().begin(), c1->getName().end(), c2->getName().begin(), c2->getName().end(), comparetolower);
|
||||||
else
|
else
|
||||||
return ((uint64_t)c1->getFreqId()<<32 | c1->polarization <<16 | c1->getSatellitePosition()) < ((uint64_t)c2->getFreqId()<<32 | c2->polarization <<16 | c2->getSatellitePosition());
|
return ((uint64_t)c1->getFreqId()<<32 | c1->polarization <<16 | abs(c1->getSatellitePosition())) < ((uint64_t)c2->getFreqId()<<32 | c2->polarization <<16 | abs(c2->getSatellitePosition()));
|
||||||
;
|
;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user