add ability to clear transponders to scan when first NIT is received
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>
Tue, 10 Oct 2006 17:29:20 +0000 (17:29 +0000)
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>
Tue, 10 Oct 2006 17:29:20 +0000 (17:29 +0000)
lib/dvb/scan.cpp
lib/dvb/scan.h

index 8aa41df..00564cd 100644 (file)
@@ -357,6 +357,11 @@ void eDVBScan::channelDone()
        if (m_ready & validNIT)
        {
                SCAN_eDebug("dumping NIT");
+               if (m_flags & clearToScanOnFirstNIT)
+               {
+                       m_ch_toScan.clear();
+                       m_flags &= ~clearToScanOnFirstNIT;
+               }
                std::vector<NetworkInformationSection*>::const_iterator i;
                for (i = m_NIT->getSections().begin(); i != m_NIT->getSections().end(); ++i)
                {
index 656817f..96a1528 100644 (file)
@@ -73,7 +73,11 @@ public:
        eDVBScan(iDVBChannel *channel, bool usePAT=true, bool debug=true );
        ~eDVBScan();
 
-       enum { scanNetworkSearch = 1, scanSearchBAT = 2, scanRemoveServices = 4, scanDontRemoveFeeds=8 };
+       enum {
+               scanNetworkSearch = 1, scanSearchBAT = 2,
+               scanRemoveServices = 4, scanDontRemoveFeeds = 8,
+               clearToScanOnFirstNIT = 16 };
+
        void start(const eSmartPtrList<iDVBFrontendParameters> &known_transponders, int flags);
 
        enum { evtUpdate, evtNewService, evtFinish, evtFail };