summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-19 23:04:11 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-19 23:04:11 +0300
commitf1fcca9730e0224668e5edd74856bd4a816adee4 (patch)
treed28fe367d28b5d930fa539c83b0c6a72133a73b3
parent0a4ee3a9df73daf0350080b9e147f7b4bd535429 (diff)
downloadmanaplus-f1fcca9730e0224668e5edd74856bd4a816adee4.tar.gz
manaplus-f1fcca9730e0224668e5edd74856bd4a816adee4.tar.bz2
manaplus-f1fcca9730e0224668e5edd74856bd4a816adee4.tar.xz
manaplus-f1fcca9730e0224668e5edd74856bd4a816adee4.zip
Fix reading packet SMSG_PARTY_INFO if it was sent in wrong way.
-rw-r--r--src/net/eathena/partyrecv.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/net/eathena/partyrecv.cpp b/src/net/eathena/partyrecv.cpp
index 4fdb37ef2..f509d55c5 100644
--- a/src/net/eathena/partyrecv.cpp
+++ b/src/net/eathena/partyrecv.cpp
@@ -135,8 +135,9 @@ void PartyRecv::processPartyInfo(Net::MessageIn &msg)
Ea::taParty->clearMembers();
const int length = msg.readInt16("len");
+ const std::string name = msg.readString(24, "party name");
if (Ea::taParty)
- Ea::taParty->setName(msg.readString(24, "party name"));
+ Ea::taParty->setName(name);
const int count = (length - 28) / 46;
if (localPlayer && Ea::taParty)