Ticket #8251: 8251-v1.patch

File 8251-v1.patch, 1.4 KB (added by danielk, 12 years ago)

Possible fix.

  • mythtv/libs/libmythtv/tv_rec.cpp

    diff --git a/mythtv/libs/libmythtv/tv_rec.cpp b/mythtv/libs/libmythtv/tv_rec.cpp
    index 24a6942..2ec1e05 100644
    a b void TVRec::run(void) 
    12041204
    12051205    eitScanStartTime = QDateTime::currentDateTime();
    12061206    // check whether we should use the EITScanner in this TVRec instance
     1207    bool scanning_possible = false;
    12071208    if (CardUtil::IsEITCapable(genOpt.cardtype) &&
    12081209        (!GetDTVChannel() || GetDTVChannel()->IsMaster()) &&
    12091210        (dvbOpt.dvb_eitscan || get_use_eit(cardid)))
    12101211    {
     1212        vector<uint> inputids = CardUtil::GetInputIDs(cardid);
     1213        scanning_possible = !inputids.empty();
     1214        const QString main_dev = CardUtil::GetVideoDevice(cardid);
     1215        for (uint j = 0; j < inputids.size() && scanning_possible; j++)
     1216        {
     1217            vector<uint> cardids =
     1218                CardUtil::GetConflictingCards(inputids[j], cardid);
     1219            for (uint i = 0; i < cardids.size() && scanning_possible; i++)
     1220            {
     1221                scanning_possible &=
     1222                    (main_dev == CardUtil::GetVideoDevice(cardids[i]));
     1223            }
     1224        }
     1225    }     
     1226
     1227    if (scanning_possible)
     1228    {
    12111229        scanner = new EITScanner(cardid);
    12121230        uint timeout = eitCrawlIdleStart;
    12131231        // get the number of capture cards and the position of the current card