mirror of
https://github.com/GeyserMC/MCProtocolLib.git
synced 2024-12-04 12:51:09 -05:00
Ensure connection process has fully completed before ending wait loop.
This commit is contained in:
parent
c68659008b
commit
4c06294c88
1 changed files with 5 additions and 3 deletions
|
@ -96,15 +96,17 @@ public class TcpClientSession extends TcpSession {
|
|||
future.addListener(new ChannelFutureListener() {
|
||||
@Override
|
||||
public void operationComplete(ChannelFuture future) throws Exception {
|
||||
complete.set(true);
|
||||
if(!future.isSuccess() && future.cause() != null) {
|
||||
exceptionCaught(null, future.cause());
|
||||
}
|
||||
}
|
||||
});
|
||||
} catch(Throwable t) {
|
||||
}).await();
|
||||
|
||||
complete.set(true);
|
||||
} catch(Throwable t) {
|
||||
exceptionCaught(null, t);
|
||||
|
||||
complete.set(true);
|
||||
}
|
||||
}
|
||||
}).start();
|
||||
|
|
Loading…
Reference in a new issue