Ticket #3031: 3031-dbg-6.patch

File 3031-dbg-6.patch, 6.1 KB (added by danielk, 13 years ago)

Another debugging patch

  • libs/libmythtv/mpeg/mpegstreamdata.cpp

     
    7676
    7777MPEGStreamData::~MPEGStreamData()
    7878{
    79     Reset(-1);
     79    Reset(-1, "~MPEGStreamData()");
    8080    SetPATSingleProgram(NULL);
    8181    SetPMTSingleProgram(NULL);
    8282
     
    120120    ReturnCachedPATTables(pats);
    121121
    122122    if (reset)
    123         Reset(p);
     123        Reset(p, "SetDesiredProgram(int)");
    124124}
    125125
    126126void MPEGStreamData::SetEITHelper(EITHelper *eit_helper)
     
    135135    _eit_rate = rate;
    136136}
    137137
    138 void MPEGStreamData::Reset(int desiredProgram)
     138void MPEGStreamData::Reset(int desiredProgram, const QString &where)
    139139{
     140    VERBOSE(VB_IMPORTANT,
     141            QString("MPEGStreamData::Reset(int) called from %1").arg(where));
     142
    140143    _desired_program = desiredProgram;
    141144    _invalid_pat_seen = false;
    142145
  • libs/libmythtv/mpeg/atscstreamdata.cpp

     
    4444
    4545ATSCStreamData::~ATSCStreamData()
    4646{
    47     Reset(-1,-1);
     47    Reset(-1,-1, "~ATSCStreamData");
    4848
    4949    QMutexLocker locker(&_listener_lock);
    5050    _atsc_main_listeners.clear();
     
    102102    ReturnCachedCVCTTables(cvcts);
    103103
    104104    if (reset)
    105         Reset(major, minor);
     105        Reset(major, minor, "ATSCStreamData::SetDesiredChannel(int,int)");
    106106}
    107107
    108 void ATSCStreamData::Reset(int desiredProgram)
     108void ATSCStreamData::Reset(int desiredProgram, const QString &where)
    109109{
    110     Reset(-1,-1);
    111     MPEGStreamData::Reset(desiredProgram);
     110    VERBOSE(VB_IMPORTANT,
     111            QString("ATSCStreamData::Reset(int) called from %1").arg(where));
     112
     113    Reset(-1,-1, "ATSCStreamData::Reset(int)");
     114
     115    MPEGStreamData::Reset(desiredProgram, "ATSCStreamData::Reset(int)");
    112116    AddListeningPID(ATSC_PSIP_PID);
    113117}
    114118
    115 void ATSCStreamData::Reset(int major, int minor)
     119void ATSCStreamData::Reset(int major, int minor, const QString &where)
    116120{
     121    VERBOSE(VB_IMPORTANT,
     122            QString("ATSCStreamData::Reset(int,int) called from %1")
     123            .arg(where));
     124
    117125    _desired_major_channel = major;
    118126    _desired_minor_channel = minor;
    119127   
    120     MPEGStreamData::Reset(-1);
     128    MPEGStreamData::Reset(-1, "ATSCStreamData::Reset(int,int)");
    121129    _mgt_version = -1;
    122130    _tvct_version.clear();
    123131    _cvct_version.clear();
  • libs/libmythtv/mpeg/dvbstreamdata.cpp

     
    167167void DVBStreamData::Reset(uint desired_netid, uint desired_tsid,
    168168                          int desired_serviceid)
    169169{
    170     MPEGStreamData::Reset(desired_serviceid);
     170    MPEGStreamData::Reset(desired_serviceid, "DVBStreamData::Reset()");
    171171
    172172    _desired_netid = desired_netid;
    173173    _desired_tsid  = desired_tsid;
  • libs/libmythtv/mpeg/mpegstreamdata.h

     
    7474    virtual ~MPEGStreamData();
    7575
    7676    void SetCaching(bool cacheTables) { _cache_tables = cacheTables; }
    77     virtual void Reset(int desiredProgram);
     77    virtual void Reset(int desiredProgram, const QString &where);
    7878
    7979    /// \brief Current Offset from computer time to DVB time in seconds
    8080    double TimeOffset(void) const;
  • libs/libmythtv/mpeg/atscstreamdata.h

     
    2727                   bool cacheTables = false);
    2828   ~ATSCStreamData();
    2929
    30     void Reset(void) { Reset(-1, -1); }
    31     void Reset(int desiredProgram);
    32     void Reset(int desiredMajorChannel, int desiredMinorChannel);
     30    void Reset(const QString &where) { Reset(-1, -1, where); }
     31    void Reset(int desiredProgram, const QString &where);
     32    void Reset(int desiredMajorChannel, int desiredMinorChannel,
     33               const QString &where);
    3334    void SetDesiredChannel(int major, int minor);
    3435
    3536    // Table processing
  • libs/libmythtv/mpeg/scanstreamdata.cpp

     
    3434
    3535void ScanStreamData::Reset(void)
    3636{
    37     MPEGStreamData::Reset(-1);
    38     ATSCStreamData::Reset(-1,-1);
     37    MPEGStreamData::Reset(-1, "ScanStreamData::Reset()");
     38    ATSCStreamData::Reset(-1,-1, "ScanStreamData::Reset()");
    3939    DVBStreamData::Reset(0,0,-1);
    4040
    4141    AddListeningPID(MPEG_PAT_PID);
  • libs/libmythtv/iptvrecorder.cpp

     
    7575        Open();
    7676
    7777    if (_stream_data)
    78         _stream_data->Reset(_stream_data->DesiredProgram());
     78        _stream_data->Reset(_stream_data->DesiredProgram(), "iptvrecorder.cpp:78");
    7979
    8080    DTVRecorder::Unpause();
    8181
  • libs/libmythtv/tv_rec.cpp

     
    16881688                GetDTVRecorder()->SetStreamData(asd);
    16891689        }
    16901690
    1691         asd->Reset(major, minor);
     1691        asd->Reset(major, minor, "tv_rec.cpp:1691");
    16921692        sm->SetStreamData(sd);
    16931693        sm->SetChannel(major, minor);
    16941694        sd->SetVideoStreamsRequired(neededVideo);
     
    17681768            sd->SetIgnoreCRC(GetDVBChannel()->HasCRCBug());
    17691769#endif // USING_DVB
    17701770
    1771         sd->Reset(progNum);
     1771        sd->Reset(progNum, "tv_rec.cpp:1771");
    17721772        sm->SetStreamData(sd);
    17731773        sm->SetProgramNumber(progNum);
    17741774        sd->SetVideoStreamsRequired(neededVideo);