Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
clear streams when closing the demuxer, not on each channel switch
  • Loading branch information
Jalle19 committed Jan 4, 2014
1 parent 2e82c09 commit d764198
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
3 changes: 1 addition & 2 deletions addons/pvr.hts/src/HTSPDemux.cpp
Expand Up @@ -68,6 +68,7 @@ void CHTSPDemux::Close()
if (m_session->IsConnected() && m_subs > 0)
SendUnsubscribe(m_subs);
m_subs = 0;
m_streams.Clear();
}

void CHTSPDemux::SetSpeed(int speed)
Expand Down Expand Up @@ -400,8 +401,6 @@ void CHTSPDemux::ParseSubscriptionStart(htsmsg_t *m)
void CHTSPDemux::ParseSubscriptionStop(htsmsg_t *m)
{
XBMC->Log(LOG_INFO, "%s - subscription ended on adapter %s", __FUNCTION__, m_SourceInfo.si_adapter.c_str());
CLockObject lock(m_mutex);
m_streams.Clear();

/* reset the signal status */
m_Quality.fe_status = "";
Expand Down
7 changes: 6 additions & 1 deletion addons/pvr.vdr.vnsi/src/VNSIDemux.cpp
Expand Up @@ -60,6 +60,12 @@ void cVNSIDemux::Abort()
m_streams.Clear();
}

void cVNSIDemux::Close()
{
m_streams.Clear();
cVNSISession::Close();
}

DemuxPacket* cVNSIDemux::Read()
{
if(ConnectionLost())
Expand Down Expand Up @@ -219,7 +225,6 @@ bool cVNSIDemux::SwitchChannel(const PVR_CHANNEL &channelinfo)
}

m_channelinfo = channelinfo;
m_streams.Clear();
m_MuxPacketSerial = 0;
m_ReferenceTime = 0;
m_BufferTimeStart = 0;
Expand Down
1 change: 1 addition & 0 deletions addons/pvr.vdr.vnsi/src/VNSIDemux.h
Expand Up @@ -47,6 +47,7 @@ class cVNSIDemux : public cVNSISession

bool OpenChannel(const PVR_CHANNEL &channelinfo);
void Abort();
void Close();
bool GetStreamProperties(PVR_STREAM_PROPERTIES* props);
DemuxPacket* Read();
bool SwitchChannel(const PVR_CHANNEL &channelinfo);
Expand Down

0 comments on commit d764198

Please sign in to comment.