summaryrefslogtreecommitdiff
path: root/src/net/eathena/traderecv.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-04-02 20:40:58 +0300
committerAndrei Karas <akaras@inbox.ru>2016-04-02 20:40:58 +0300
commita08ed94e63c099467e65e98dc003b33c8e9c2034 (patch)
tree72e910fef12af86c4dd4925d7d104a0529ad369e /src/net/eathena/traderecv.cpp
parent013284123a69dfe15016b8823ecc8b8bed54c561 (diff)
downloadmanaplus-a08ed94e63c099467e65e98dc003b33c8e9c2034.tar.gz
manaplus-a08ed94e63c099467e65e98dc003b33c8e9c2034.tar.bz2
manaplus-a08ed94e63c099467e65e98dc003b33c8e9c2034.tar.xz
manaplus-a08ed94e63c099467e65e98dc003b33c8e9c2034.zip
Sort more packets. Add version checks inside packets.
Diffstat (limited to 'src/net/eathena/traderecv.cpp')
-rw-r--r--src/net/eathena/traderecv.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/net/eathena/traderecv.cpp b/src/net/eathena/traderecv.cpp
index 373884dac..37f2b0dbc 100644
--- a/src/net/eathena/traderecv.cpp
+++ b/src/net/eathena/traderecv.cpp
@@ -55,8 +55,11 @@ namespace TradeRecv
void TradeRecv::processTradeRequest(Net::MessageIn &msg)
{
const std::string &partner = msg.readString(24, "name");
- msg.readInt32("char id");
- msg.readInt16("base level");
+ if (msg.getVersion() >= 6)
+ {
+ msg.readInt32("char id");
+ msg.readInt16("base level");
+ }
Ea::TradeRecv::processTradeRequestContinue(partner);
}