diff options
author | Christian Wieninger <cwieninger (at) gmx (dot) de> | 2009-02-19 20:29:24 +0100 |
---|---|---|
committer | Christian Wieninger <cwieninger (at) gmx (dot) de> | 2009-02-19 20:29:24 +0100 |
commit | d5d59f964996c24019898e0573067b919fa83a6f (patch) | |
tree | acbdb7d19f9083c77cb67b52b3c204defb623fca /tntconfig.cpp | |
parent | 3b53981b41a59c7935e372a56737c14857432bae (diff) | |
parent | e3343f602dfe288afa1f027563d307d049d95c1e (diff) | |
download | vdr-plugin-live-d5d59f964996c24019898e0573067b919fa83a6f.tar.gz vdr-plugin-live-d5d59f964996c24019898e0573067b919fa83a6f.tar.bz2 |
Merge commit 'tadi/master'
Conflicts:
README
setup.cpp
Diffstat (limited to 'tntconfig.cpp')
-rw-r--r-- | tntconfig.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/tntconfig.cpp b/tntconfig.cpp index 23943a5..d35dad4 100644 --- a/tntconfig.cpp +++ b/tntconfig.cpp @@ -252,8 +252,19 @@ namespace vdrlive { Setup::IpList const& ips = LiveSetup().GetServerIps(); int port = LiveSetup().GetServerPort(); + size_t listenFailures = 0; for ( Setup::IpList::const_iterator ip = ips.begin(); ip != ips.end(); ++ip ) { - app.listen(*ip, port); + try { + app.listen(*ip, port); + } + catch (exception const & ex) { + esyslog("ERROR: live ip = %s is invalid: exception = %s", ip->c_str(), ex.what()); + if (++listenFailures == ips.size()) { + // if no listener was initialized we throw at + // least the last exception to the next layer. + throw; + } + } } #if TNTSSLSUPPORT |