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

Add smack-bosh to Android Projects

Replace SaslException with SmackException in XMPPBOSHConnection, that is
the exception which is used in XMPPTCPConnection for the same purpose.

Also make androidProjects a multi-line list.
This commit is contained in:
Florian Schmaus 2015-01-25 10:35:44 +01:00
parent 4b10f36e9e
commit 616768a5a9
2 changed files with 12 additions and 5 deletions

View file

@ -25,8 +25,6 @@ import java.io.Writer;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.security.sasl.SaslException;
import org.jivesoftware.smack.AbstractXMPPConnection;
import org.jivesoftware.smack.SmackException;
import org.jivesoftware.smack.SmackException.NotConnectedException;
@ -239,7 +237,7 @@ public class XMPPBOSHConnection extends AbstractXMPPConnection {
saslAuthentication.authenticate(resource, config.getCallbackHandler());
}
} else {
throw new SaslException("No non-anonymous SASL authentication mechanism available");
throw new SmackException("No non-anonymous SASL authentication mechanism available");
}
bindResourceAndEstablishSession(resource);
@ -257,7 +255,7 @@ public class XMPPBOSHConnection extends AbstractXMPPConnection {
}
else {
// Authenticate using Non-SASL
throw new SaslException("No anonymous SASL authentication mechanism available");
throw new SmackException("No anonymous SASL authentication mechanism available");
}
bindResourceAndEstablishSession(null);