- try {
- new Thread() {
- public void run() {
- try {
- accept(new Connection(s, "megacz.com"));
- } catch (Exception e) { Log.error(Main.class, e); }
- }
- }.start();
- } catch (Exception e) { Log.error(Main.class, e); }
+ threadPool.start(new Runnable() {
+ public void run() {
+ try {
+ accept(new Connection(s, "megacz.com"));
+ } catch (Throwable t) { Log.error(Main.class, t); }
+ }
+ });
+ } catch (Throwable t) {
+ Log.error(Main.class, t);
+ Misc.sleep(1000);