X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fclient%2Fclientauthhandler.cpp;h=acd670d9882911c4c97c0515ac95983121fd36a3;hb=98144aaad0cd747f186edcd0e36a1d67326ac766;hp=a29505f990187645504c3cb5ae940a1a291ecdac;hpb=ab7ef4d24f62b5848b628482b7762ebfc0b53e1a;p=quassel.git diff --git a/src/client/clientauthhandler.cpp b/src/client/clientauthhandler.cpp index a29505f9..acd670d9 100644 --- a/src/client/clientauthhandler.cpp +++ b/src/client/clientauthhandler.cpp @@ -58,7 +58,7 @@ void ClientAuthHandler::connectToCore() CoreAccountSettings s; #ifdef HAVE_SSL - QSslSocket *socket = new QSslSocket(this); + auto *socket = new QSslSocket(this); // make sure the warning is shown if we happen to connect without SSL support later s.setAccountValue("ShowNoClientSslWarning", true); #else @@ -237,8 +237,8 @@ void ClientAuthHandler::onReadyRead() socket()->read((char *)&reply, 4); reply = qFromBigEndian(reply); - Protocol::Type type = static_cast(reply & 0xff); - quint16 protoFeatures = static_cast(reply>>8 & 0xffff); + auto type = static_cast(reply & 0xff); + auto protoFeatures = static_cast(reply>>8 & 0xffff); _connectionFeatures = static_cast(reply>>24); Compressor::CompressionLevel level; @@ -411,10 +411,10 @@ void ClientAuthHandler::handle(const LoginSuccess &msg) void ClientAuthHandler::handle(const SessionState &msg) { - disconnect(socket(), 0, this, 0); // this is the last message we shall ever get + disconnect(socket(), nullptr, this, nullptr); // this is the last message we shall ever get // give up ownership of the peer; CoreSession takes responsibility now - _peer->setParent(0); + _peer->setParent(nullptr); emit handshakeComplete(_peer, msg); } @@ -431,7 +431,7 @@ void ClientAuthHandler::checkAndEnableSsl(bool coreSupportsSsl) // Make sure the warning is shown next time we don't have SSL in the core s.setAccountValue("ShowNoCoreSslWarning", true); - QSslSocket *sslSocket = qobject_cast(socket()); + auto *sslSocket = qobject_cast(socket()); Q_ASSERT(sslSocket); connect(sslSocket, SIGNAL(encrypted()), SLOT(onSslSocketEncrypted())); connect(sslSocket, SIGNAL(sslErrors(QList)), SLOT(onSslErrors())); @@ -463,7 +463,7 @@ void ClientAuthHandler::checkAndEnableSsl(bool coreSupportsSsl) void ClientAuthHandler::onSslSocketEncrypted() { - QSslSocket *socket = qobject_cast(sender()); + auto *socket = qobject_cast(sender()); Q_ASSERT(socket); if (!socket->sslErrors().count()) { @@ -485,7 +485,7 @@ void ClientAuthHandler::onSslSocketEncrypted() void ClientAuthHandler::onSslErrors() { - QSslSocket *socket = qobject_cast(sender()); + auto *socket = qobject_cast(sender()); Q_ASSERT(socket); CoreAccountSettings s;