diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-08-31 00:35:38 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-09-06 01:18:53 +0300 |
commit | 86273941131b643ba470a1604e4f2d808306d42c (patch) | |
tree | a9fefc41a1bfd1fdd843bb5a8218007af8f2b9ed /src/net | |
parent | b2db639b28d2183d18ba189d5b937605e0a73ae1 (diff) | |
download | manaplus-86273941131b643ba470a1604e4f2d808306d42c.tar.gz manaplus-86273941131b643ba470a1604e4f2d808306d42c.tar.bz2 manaplus-86273941131b643ba470a1604e4f2d808306d42c.tar.xz manaplus-86273941131b643ba470a1604e4f2d808306d42c.zip |
In eathena remove packet SMSG_SERVER_VERSION_RESPONSE.
Diffstat (limited to 'src/net')
-rw-r--r-- | src/net/eathena/loginhandler.cpp | 18 | ||||
-rw-r--r-- | src/net/eathena/loginhandler.h | 6 | ||||
-rw-r--r-- | src/net/eathena/network.cpp | 10 |
3 files changed, 6 insertions, 28 deletions
diff --git a/src/net/eathena/loginhandler.cpp b/src/net/eathena/loginhandler.cpp index 150b47b91..8eb3099af 100644 --- a/src/net/eathena/loginhandler.cpp +++ b/src/net/eathena/loginhandler.cpp @@ -55,7 +55,6 @@ LoginHandler::LoginHandler() : SMSG_LOGIN_ERROR, SMSG_LOGIN_ERROR2, SMSG_CHAR_PASSWORD_RESPONSE, - SMSG_SERVER_VERSION_RESPONSE, 0 }; handledMessages = _messages; @@ -94,10 +93,6 @@ void LoginHandler::handleMessage(Net::MessageIn &msg) processLoginError2(msg); break; - case SMSG_SERVER_VERSION_RESPONSE: - processServerVersion(msg); - break; - default: break; } @@ -169,19 +164,6 @@ void LoginHandler::requestUpdateHosts() outMsg.writeInt8(0); // unused } -void LoginHandler::processServerVersion(Net::MessageIn &msg) -{ - msg.readUInt8(); - msg.readUInt8(); - msg.readUInt8(); - msg.readUInt8(); - msg.readInt32(); - mRegistrationEnabled = true; - serverVersion = 0; - if (client->getState() != STATE_LOGIN) - client->setState(STATE_LOGIN); -} - void LoginHandler::processUpdateHost2(Net::MessageIn &msg) const { const int len = msg.readInt16() - 4; diff --git a/src/net/eathena/loginhandler.h b/src/net/eathena/loginhandler.h index 60cde7df7..c2e7216d6 100644 --- a/src/net/eathena/loginhandler.h +++ b/src/net/eathena/loginhandler.h @@ -62,8 +62,6 @@ class LoginHandler final : public MessageHandler, public Ea::LoginHandler ServerInfo *getCharServer() const override final A_WARN_UNUSED; - void processServerVersion(Net::MessageIn &msg); - static void requestUpdateHosts(); void processUpdateHost2(Net::MessageIn &msg) const; @@ -75,6 +73,10 @@ class LoginHandler final : public MessageHandler, public Ea::LoginHandler const std::string &restrict password, const std::string &restrict email) const override final; + + // unused + void processServerVersion(Net::MessageIn &msg) + { } }; } // namespace EAthena diff --git a/src/net/eathena/network.cpp b/src/net/eathena/network.cpp index ab83de085..76c4702d6 100644 --- a/src/net/eathena/network.cpp +++ b/src/net/eathena/network.cpp @@ -272,11 +272,7 @@ void Network::dispatchMessages() SDL_mutexP(mMutexIn); const unsigned int msgId = readWord(0); int len = -1; - if (msgId == SMSG_SERVER_VERSION_RESPONSE) - { - len = 10; - } - else if (msgId == SMSG_UPDATE_HOST2) + if (msgId == SMSG_UPDATE_HOST2) { len = -1; } @@ -322,9 +318,7 @@ bool Network::messageReady() if (mInSize >= 2) { const int msgId = readWord(0); - if (msgId == SMSG_SERVER_VERSION_RESPONSE) - len = 10; - else if (msgId == SMSG_UPDATE_HOST2) + if (msgId == SMSG_UPDATE_HOST2) len = -1; else len = packet_lengths[msgId]; |