diff options
-rw-r--r-- | setup.cpp | 2 | ||||
-rw-r--r-- | setup.h | 5 |
2 files changed, 3 insertions, 4 deletions
@@ -4,7 +4,6 @@ #include <algorithm> #include <functional> #include <iostream> -#include <numeric> #include <sstream> #include <getopt.h> #include <stdint.h> @@ -66,7 +65,6 @@ char const* Setup::CommandLineHelp() const bool Setup::ParseSetupEntry( char const* name, char const* value ) { - cout << "Parsing " << name << " = " << value << endl; if ( strcmp( name, "LastChannel" ) == 0 ) m_lastChannel = atoi( value ); else return false; return true; @@ -1,8 +1,9 @@ #ifndef VDR_LIVE_SETUP_H #define VDR_LIVE_SETUP_H -#include <string> #include <list> +#include <numeric> +#include <string> #include "live.h" namespace vdrlive { @@ -21,7 +22,7 @@ public: int GetServerPort() const { return m_serverPort; } IpList const& GetServerIps() const { return m_serverIps; } // vdr-setup - int GetLastChannel() const { return m_lastChannel; } + int GetLastChannel() const { return m_lastChannel == 0 ? std::numeric_limits< int >::max() : m_lastChannel; } bool ParseCommandLine( int argc, char* argv[] ); char const* CommandLineHelp() const; |