From: ishmal Date: Sun, 21 May 2006 21:14:09 +0000 (+0000) Subject: Check if we are already SSL before trying STARTTLS X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=81a24f5b251682d5f320c0907efcb047a22102c0;p=inkscape.git Check if we are already SSL before trying STARTTLS --- diff --git a/src/pedro/pedroxmpp.cpp b/src/pedro/pedroxmpp.cpp index f447b9356..6bce6c10e 100644 --- a/src/pedro/pedroxmpp.cpp +++ b/src/pedro/pedroxmpp.cpp @@ -1146,6 +1146,8 @@ public: void enableSSL(bool val); + bool getEnableSSL(); + bool connect(const std::string &hostname, int portno); bool connect(const char *hostname, int portno); @@ -1376,6 +1378,11 @@ void TcpSocket::enableSSL(bool val) sslEnabled = val; } +bool TcpSocket::getEnableSSL() +{ + return sslEnabled; +} + bool TcpSocket::connect(const char *hostnameArg, int portnoArg) { @@ -3477,7 +3484,7 @@ bool XmppClient::saslAuthenticate() status("login: STARTTLS available"); } - if (wantStartTls) + if (wantStartTls && !sock->getEnableSSL()) { delete elem; char *fmt =