mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 17:19:39 +02:00
Add more information to NotConnectedException
This commit is contained in:
parent
a854e04d28
commit
a85ba5311e
2 changed files with 12 additions and 2 deletions
|
@ -1210,9 +1210,14 @@ public class XMPPTCPConnection extends AbstractXMPPConnection {
|
|||
}
|
||||
|
||||
protected void throwNotConnectedExceptionIfDoneAndResumptionNotPossible() throws NotConnectedException {
|
||||
if (done() && !isSmResumptionPossible()) {
|
||||
final boolean done = done();
|
||||
if (done) {
|
||||
final boolean smResumptionPossbile = isSmResumptionPossible();
|
||||
// Don't throw a NotConnectedException is there is an resumable stream available
|
||||
throw new NotConnectedException();
|
||||
if (!smResumptionPossbile) {
|
||||
throw new NotConnectedException(XMPPTCPConnection.this, "done=" + done
|
||||
+ " smResumptionPossible=" + smResumptionPossbile);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue