X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fclient%2Fclientsyncer.cpp;h=daff617636999094b2dd0fd7c4f3fdbb849e8451;hb=d450c85dadf1f813e3274e7c33440a320d876c18;hp=be5c95b8cb9b9cee6f04167706bd34056614e739;hpb=613850196857c7e29b0ef5c09175aadb9492642d;p=quassel.git
diff --git a/src/client/clientsyncer.cpp b/src/client/clientsyncer.cpp
index be5c95b8..daff6176 100644
--- a/src/client/clientsyncer.cpp
+++ b/src/client/clientsyncer.cpp
@@ -186,8 +186,10 @@ void ClientSyncer::coreSocketDisconnected() {
void ClientSyncer::clientInitAck(const QVariantMap &msg) {
// Core has accepted our version info and sent its own. Let's see if we accept it as well...
- if((msg.contains("CoreBuild") && msg["CoreBuild"].toUInt() < 732) // legacy!
- || (!msg.contains("CoreBuild") && msg["ProtocolVersion"].toUInt() < Global::clientNeedsProtocol)) {
+ uint ver = 0;
+ if(!msg.contains("ProtocolVersion") && msg["CoreBuild"].toUInt() >= 732) ver = 1; // legacy!
+ if(msg.contains("ProtocolVersion")) ver = msg["ProtocolVersion"].toUInt();
+ if(ver < Global::clientNeedsProtocol) {
emit connectionError(tr("The Quassel Core you are trying to connect to is too old!
"
"Need at least core/client protocol v%1 to connect.").arg(Global::clientNeedsProtocol));
disconnectFromCore();