X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fnetworkinterface.cpp;fp=source%2Fnetworkinterface.cpp;h=29947e84574701ea5e2c3c36e833636f5f8124ac;hb=a1e6d14ce3a5d5415333a4d3def6c5504f4bc49b;hp=e5283b6ff96791c068b334e0a42ea1a0d102ad91;hpb=2e629085885b652a10d775695e63bc4892aa2eca;p=xinema.git diff --git a/source/networkinterface.cpp b/source/networkinterface.cpp index e5283b6..29947e8 100644 --- a/source/networkinterface.cpp +++ b/source/networkinterface.cpp @@ -1,3 +1,4 @@ +#include #include #include #include "client.h" @@ -68,7 +69,14 @@ void NetworkInterface::NetworkThread::main() { while(!done) { - network.event_disp.tick(); + try + { + network.event_disp.tick(); + } + catch(const std::exception &e) + { + IO::print(IO::cerr, "Unhandled exception in network thread: %s\n", e.what()); + } for(list::iterator i=network.clients.begin(); i!=network.clients.end(); ) {