Ticket #12146: livetv3min.patch

File livetv3min.patch, 2.8 KB (added by JYA, 6 years ago)
  • mythtv/libs/libmythbase/threadedfilewriter.cpp

    diff --git a/mythtv/libs/libmythbase/threadedfilewriter.cpp b/mythtv/libs/libmythbase/threadedfilewriter.cpp
    old mode 100644
    new mode 100755
    index a3ec813..14ba241
    a b uint ThreadedFileWriter::Write(const void *data, uint count) 
    299299        left    -= towrite;
    300300    }
    301301
    302     LOG(VB_FILE, LOG_DEBUG, LOC + QString("Write(*, %1) total %2 cnt %3")
    303             .arg(count,4).arg(totalBufferUse).arg(writeBuffers.size()));
     302//    LOG(VB_FILE, LOG_DEBUG, LOC + QString("Write(*, %1) total %2 cnt %3")
     303//            .arg(count,4).arg(totalBufferUse).arg(writeBuffers.size()));
    304304
    305305    return count;
    306306}
  • mythtv/libs/libmythtv/ringbuffer.cpp

    diff --git a/mythtv/libs/libmythtv/ringbuffer.cpp b/mythtv/libs/libmythtv/ringbuffer.cpp
    old mode 100644
    new mode 100755
    index 5628863..fca398b
    a b int RingBuffer::ReadPriv(void *buf, int count, bool peek) 
    13941394    LOG(VB_FILE, LOG_DEBUG, LOC + loc_desc +
    13951395        QString(" @%1 -- begin").arg(rbrpos));
    13961396
     1397    if (count > 900000)
     1398    {
     1399        LOG(VB_FILE, LOG_WARNING, LOC + QString("ReadPriv > 900K (%1)").arg(count));
     1400    }
    13971401    rwlock.lockForRead();
    13981402    if (writemode)
    13991403    {
  • mythtv/libs/libmythtv/tv_rec.cpp

    diff --git a/mythtv/libs/libmythtv/tv_rec.cpp b/mythtv/libs/libmythtv/tv_rec.cpp
    index b22e169..f0e47cb 100644
    a b void TVRec::run(void) 
    13481348                pendingRecordings.find(cardid) != pendingRecordings.end();
    13491349            pendingRecLock.unlock();
    13501350
     1351            const int time_out = 180;
     1352            bool debug_start_new = false;
     1353            if (!debugNextRecTime.isValid())
     1354                debugNextRecTime = now.addSecs(time_out);
     1355            if (now >= debugNextRecTime)
     1356            {
     1357                debug_start_new = true;
     1358                debugNextRecTime = now.addSecs(time_out);
     1359            }
     1360
    13511361            if (has_rec && (has_finish || (now > recordEndTime)))
    13521362            {
    13531363                SetPseudoLiveTVRecording(NULL);
    13541364            }
    13551365            else if (!has_rec && !rec_soon && curRecording &&
    1356                      (now >= curRecording->GetScheduledEndTime()))
     1366                     (now >= curRecording->GetScheduledEndTime() ||
     1367                      debug_start_new))
    13571368            {
    13581369                if (!switchingBuffer)
    13591370                {
  • mythtv/libs/libmythtv/tv_rec.h

    diff --git a/mythtv/libs/libmythtv/tv_rec.h b/mythtv/libs/libmythtv/tv_rec.h
    index 0c2f00c..aa09f37 100644
    a b class MTV_PUBLIC TVRec : public SignalMonitorListener, public QRunnable 
    398398
    399399    // LiveTV file chain
    400400    LiveTVChain *tvchain;
     401    QDateTime debugNextRecTime;
    401402
    402403    // RingBuffer info
    403404    RingBuffer  *ringBuffer;