I2PTunnel: Catch unchecked exceptions in server accept loop (ticket #1070)

This commit is contained in:
zzz
2013-10-24 20:56:37 +00:00
parent 4aa1bba575
commit c732c1c038

View File

@@ -449,10 +449,18 @@ public class I2PTunnelServer extends I2PTunnelTask implements Runnable {
_log.error("Error accepting", ce);
// not killing the server..
try {
Thread.currentThread().sleep(500);
Thread.sleep(500);
} catch (InterruptedException ie) {}
} catch(SocketTimeoutException ste) {
// ignored, we never set the timeout
} catch (Exception e) {
// streaming borkage
if (_log.shouldLog(Log.ERROR))
_log.error("Uncaught exception accepting", e);
// not killing the server..
try {
Thread.sleep(500);
} catch (InterruptedException ie) {}
}
}
if (_executor != null)