diff options
author | Stefan Dombrowski <stefan@uni-bonn.de> | 2010-09-05 17:34:20 +0200 |
---|---|---|
committer | Stefan Dombrowski <stefan@uni-bonn.de> | 2010-09-05 17:34:20 +0200 |
commit | f82d012e96cf90556a213bf6058de43dc0a9ae7f (patch) | |
tree | 212bc3ed7a2db8aa157b92bb642a1799cbba4181 /src/net/tmwa/charserverhandler.cpp | |
parent | c99347bf9108367c02dcbdebadec0b978a750c57 (diff) | |
download | mana-f82d012e96cf90556a213bf6058de43dc0a9ae7f.tar.gz mana-f82d012e96cf90556a213bf6058de43dc0a9ae7f.tar.bz2 mana-f82d012e96cf90556a213bf6058de43dc0a9ae7f.tar.xz mana-f82d012e96cf90556a213bf6058de43dc0a9ae7f.zip |
Fixing ghost characters in charselectdialog
How to reproduce the bug: Switch the login to an account with
fewer characters. Then those character slots are not empty, but
show characters from the previous account.
Reviewed-by: thorbjorn
Diffstat (limited to 'src/net/tmwa/charserverhandler.cpp')
-rw-r--r-- | src/net/tmwa/charserverhandler.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/net/tmwa/charserverhandler.cpp b/src/net/tmwa/charserverhandler.cpp index 8711f031..dc9b3108 100644 --- a/src/net/tmwa/charserverhandler.cpp +++ b/src/net/tmwa/charserverhandler.cpp @@ -77,6 +77,9 @@ void CharServerHandler::handleMessage(Net::MessageIn &msg) msg.skip(2); // Length word msg.skip(20); // Unused + delete_all(mCharacters); + mCharacters.clear(); + // Derive number of characters from message length const int count = (msg.getLength() - 24) / 106; |