Changeset e67c750 for apps


Ignore:
Timestamp:
May 26, 2018 8:00:10 PM (2 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
00acac4
Parents:
2d7f0d3
Message:

i2ptunnel: Retry accept after server socket closed (ticket #2003)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelServer.java

    r2d7f0d3 re67c750  
    594594                if (_log.shouldLog(Log.ERROR))
    595595                    _log.error("Error accepting", ce);
    596                 open = false;
    597596                if (i2ps != null) try { i2ps.close(); } catch (IOException ioe) {}
    598                 break;
     597                try {
     598                    Thread.sleep(2*60*1000);
     599                } catch (InterruptedException ie) {}
     600                // Server socket possbily closed out from under us, perhaps as part of a router restart;
     601                // wait a while and try to get a new socket
     602                i2pss = sockMgr.getServerSocket();
    599603            } catch(SocketTimeoutException ste) {
    600604                // ignored, we never set the timeout
Note: See TracChangeset for help on using the changeset viewer.