Commit 1a8a1abe authored by Andrew de Quincey's avatar Andrew de Quincey

Adds a new parameter to DVB inputs. Allows VLS to be configured to ignore

missing DVB programs. Default is original behaviour
parent 56410655
......@@ -2,7 +2,7 @@
* dvbinput.cpp: DVB streams
*-------------------------------------------------------------------------------
* (c)1999-2002 VideoLAN
* $Id: dvbinput.cpp,v 1.31 2003/08/14 11:12:53 nitrox Exp $
* $Id: dvbinput.cpp,v 1.32 2003/08/17 00:00:17 adq Exp $
*
* Authors: Arnaud de Bossoreille de Ribou <bozo@via.ecp.fr>
* Damien Lucas <nitrox@videolan.org>
......@@ -118,6 +118,7 @@ C_DvbInput::C_DvbInput(C_Module* pModule,
m_iGotTpid = 0; // Did not set the transponder yet
m_iDemuxUsageCount = 0; // Nothing using the demux yet
m_bIgnoreTimeout = false;
m_bIgnoreMissing = false;
m_pConverter = NULL;
m_pTrickPlay = NULL;
for(int i =0; i < 512; i++)
......@@ -152,6 +153,7 @@ void C_DvbInput::OnInit()
m_strTrickPlayType = pApp->GetSetting(GetName() + ".trickplay", "Normal").ToLower();
m_iSendMethod = pApp->GetSetting(GetName() + ".sendmethod", "0").ToInt();
m_bIgnoreTimeout = pApp->GetSetting(GetName()+".ignoretimeout", "0").ToInt();
m_bIgnoreMissing = pApp->GetSetting(GetName()+".ignoremissing", "0").ToInt();
dvbrc = pApp->GetSetting(GetName()+ ".dvbrc", "");
if(dvbrc.Length() != 0)
{
......@@ -588,9 +590,15 @@ void C_DvbInput::OnStartStreaming(C_Broadcast* pBroadcast)
}
else
{
throw E_Exception(GEN_ERR, "Program \"" +
pBroadcast->GetProgram()->GetName() +
"\" doesn't exist");
if (!m_bIgnoreMissing) {
throw E_Exception(GEN_ERR, "Program \"" +
pBroadcast->GetProgram()->GetName() +
"\" doesn't exist");
} else {
Log(m_hLog, LOG_WARN, C_String("Ignoring missing program \"") +
pBroadcast->GetProgram()->GetName() +
C_String("\""));
}
}
m_cLock.UnLock();
......
......@@ -2,7 +2,7 @@
* dvbinput.h: DVB Input class definition
*-------------------------------------------------------------------------------
* (c)1999-2002 VideoLAN
* $Id: dvbinput.h,v 1.14 2003/06/02 19:50:35 jpsaman Exp $
* $Id: dvbinput.h,v 1.15 2003/08/17 00:00:17 adq Exp $
*
* Authors: Arnaud de Bossoreille de Ribou <bozo@via.ecp.fr>
*
......@@ -76,7 +76,8 @@ private:
bool m_bHasDecoder;
bool m_bIgnoreTimeout;
bool m_bIgnoreMissing;
C_Vector<C_String> m_vProgramNames;
int m_iFrequency;
int m_iPolarization;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment