sleep in a loop at the end of main method. Fixes the processes exiting after 24 days.

pull/53/head
Zlatin Balevsky 2020-10-03 14:18:58 +01:00
parent 81fa2fba1f
commit 6856a816fd
No known key found for this signature in database
GPG Key ID: A72832072D525E41
2 changed files with 4 additions and 2 deletions

View File

@ -79,7 +79,8 @@ public class HostCache {
I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY)
session.connect()
log.info("connected, going to sleep")
Thread.sleep(Integer.MAX_VALUE)
while(true)
Thread.sleep(Integer.MAX_VALUE)
}

View File

@ -54,7 +54,8 @@ class UpdateServer {
session.addMuxedSessionListener(new Listener(update), I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY)
session.connect()
log.info("Connected, going to sleep")
Thread.sleep(Integer.MAX_VALUE)
while(true)
Thread.sleep(Integer.MAX_VALUE)
}