Ticket #4328: hdhr.myth.v0.25pre-2728-gc803867.mythtv.patch

File hdhr.myth.v0.25pre-2728-gc803867.mythtv.patch, 3.8 KB (added by gnassas@…, 13 years ago)

VERBOSE -> LOG change broke the prior patch

  • mythtv/libs/libmythtv/dtvchannel.cpp

    diff --git a/mythtv/libs/libmythtv/dtvchannel.cpp b/mythtv/libs/libmythtv/dtvchannel.cpp
    index 3d30f85..626a1be 100644
    a b bool DTVChannel::SetChannelByString(const QString &channum) 
    280280    }
    281281
    282282    bool ok = true;
    283     if ((*it)->externalChanger.isEmpty())
     283    if ((*it)->name.contains("composite", Qt::CaseInsensitive) ||
     284        (*it)->name.contains("s-video", Qt::CaseInsensitive))
    284285    {
    285         if ((*it)->name.contains("composite", Qt::CaseInsensitive) ||
    286             (*it)->name.contains("s-video", Qt::CaseInsensitive))
     286        if ((*it)->externalChanger.isEmpty())
    287287        {
    288288            LOG(VB_GENERAL, LOG_WARNING, loc + "You have not set "
    289289                    "an external channel changing"
    290290                    "\n\t\t\tscript for a composite or s-video "
    291291                    "input. Channel changing will do nothing.");
    292292        }
    293         else if (isFrequency && Tune(frequency, ""))
     293    }
     294    else if (isFrequency && Tune(frequency, ""))
     295    {
     296    }
     297    else if (isFrequency)
     298    {
     299        // Initialize basic the tuning parameters
     300        DTVMultiplex tuning;
     301        if (!mplexid || !tuning.FillFromDB(tunerType, mplexid))
    294302        {
     303            LOG(VB_GENERAL, LOG_ERR, loc +
     304                    "Failed to initialize multiplex options");
     305            ok = false;
    295306        }
    296         else if (isFrequency)
     307        else
    297308        {
    298             // Initialize basic the tuning parameters
    299             DTVMultiplex tuning;
    300             if (!mplexid || !tuning.FillFromDB(tunerType, mplexid))
    301             {
    302                 LOG(VB_GENERAL, LOG_ERR, loc +
    303                         "Failed to initialize multiplex options");
    304                 ok = false;
    305             }
    306             else
    307             {
    308                 // Try to fix any problems with the multiplex
    309                 CheckOptions(tuning);
     309            // Try to fix any problems with the multiplex
     310            CheckOptions(tuning);
    310311
    311                 // Tune to proper multiplex
    312                 if (!Tune(tuning, (*it)->name))
    313                 {
    314                     LOG(VB_GENERAL, LOG_ERR, loc + "Tuning to frequency.");
     312            // Tune to proper multiplex
     313            if (!Tune(tuning, (*it)->name))
     314            {
     315                LOG(VB_GENERAL, LOG_ERR, loc + "Tuning to frequency.");
    315316
    316                     ClearDTVInfo();
    317                     ok = false;
    318                 }
     317                ClearDTVInfo();
     318                ok = false;
    319319            }
    320320        }
    321         else
    322         {
    323             ok = Tune(freqid, finetune);
    324         }
     321    }
     322    else
     323    {
     324        ok = Tune(freqid, finetune);
    325325    }
    326326
    327327    LOG(VB_CHANNEL, LOG_INFO, loc + ((ok) ? "success" : "failure"));
  • mythtv/libs/libmythtv/hdhrchannel.h

    diff --git a/mythtv/libs/libmythtv/hdhrchannel.h b/mythtv/libs/libmythtv/hdhrchannel.h
    index 85f801c..937e267 100644
    a b class HDHRChannel : public DTVChannel 
    3737        { return _tuner_types; }
    3838    virtual bool IsMaster(void) const
    3939        { return _master == NULL; }
     40    virtual bool IsExternalChannelChangeSupported(void) { return true; }
    4041
    4142    // Sets
    4243    virtual bool SetChannelByString(const QString &channum);
  • mythtv/libs/libmythtv/hdhrsignalmonitor.cpp

    diff --git a/mythtv/libs/libmythtv/hdhrsignalmonitor.cpp b/mythtv/libs/libmythtv/hdhrsignalmonitor.cpp
    index a080882..c40c64e 100644
    a b void HDHRSignalMonitor::UpdateValues(void) 
    9191    if (!running || exit)
    9292        return;
    9393
     94    SignalMonitor::UpdateValues();
     95
     96    {
     97        QMutexLocker locker(&statusLock);
     98        if (!scriptStatus.IsGood())
     99            return;
     100    }
     101
    94102    if (streamHandlerStarted)
    95103    {
    96104        EmitStatus();