diff options
author | Sascha Volkenandt <sascha (at) akv-soft (dot) de> | 2007-01-02 21:09:12 +0000 |
---|---|---|
committer | Sascha Volkenandt <sascha (at) akv-soft (dot) de> | 2007-01-02 21:09:12 +0000 |
commit | 68815423f7e6ebd3c1a84356f6c8a830a59f366c (patch) | |
tree | a50da6d4d4778f073d0732f141e08db7c89a969f /tntconfig.cpp | |
parent | ca0bfd1b2dce21dbf824d094fd65e1fa9ade3721 (diff) | |
download | vdr-plugin-live-68815423f7e6ebd3c1a84356f6c8a830a59f366c.tar.gz vdr-plugin-live-68815423f7e6ebd3c1a84356f6c8a830a59f366c.tar.bz2 |
- added options -i and -p to specify port and (possibly multiple) ip(s)
- moved commandline-helpstring to setup class to ease maintaining
- added default library directory /usr/local/lib
Diffstat (limited to 'tntconfig.cpp')
-rw-r--r-- | tntconfig.cpp | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/tntconfig.cpp b/tntconfig.cpp index 1b0aadf..3735db2 100644 --- a/tntconfig.cpp +++ b/tntconfig.cpp @@ -32,10 +32,15 @@ void TntConfig::WriteConfig() } // XXX modularize - file << "MapUrl /([^.]+)(\\..+)? $1@libtnt-live" << std::endl; - file << "Listen 0.0.0.0 8003" << std::endl; - file << "PropertyFile " << m_propertiesPath << std::endl; - file << "CompPath " << Setup::Get().GetLibraryPath() << "/" << std::endl; + file << "MapUrl /([^.]+)(\\..+)? $1@libtnt-live" << endl; + file << "PropertyFile " << m_propertiesPath << endl; + file << "CompPath " << Setup::Get().GetLibraryPath() << endl; + + Setup::IpList const& ips = Setup::Get().GetServerIps(); + int port = Setup::Get().GetServerPort(); + for ( Setup::IpList::const_iterator ip = ips.begin(); ip != ips.end(); ++ip ) { + file << "Listen " << *ip << " " << port << endl; + } } void TntConfig::WriteProperties() @@ -52,8 +57,8 @@ void TntConfig::WriteProperties() } // XXX modularize - file << "rootLogger=INFO" << std::endl; - file << "logger.tntnet=INFO" << std::endl; + file << "rootLogger=INFO" << endl; + file << "logger.tntnet=INFO" << endl; } TntConfig const& TntConfig::Get() |