1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2025-09-10 09:39:39 +02:00

Call shutdown() in connect() on exception

to clean up the state build up by connect().

Related to SMACK-855 there is the possiblitiy of a stray (writer)
thread if, for example, tlsHandled.checkifSuccessOrWaitorThrow() in
XMPPTCPConnection.connectInternal() throws. This commit should prevent
that.
This commit is contained in:
Florian Schmaus 2019-03-04 17:08:53 +01:00
parent f4ebd530e6
commit f602de8771
4 changed files with 29 additions and 11 deletions

View file

@ -100,6 +100,11 @@ public class DummyConnection extends AbstractXMPPConnection {
callConnectionClosedListener();
}
@Override
public void instantShutdown() {
shutdown();
}
@Override
public boolean isSecureConnection() {
return false;
@ -226,4 +231,5 @@ public class DummyConnection extends AbstractXMPPConnection {
}
}
}
}