diff options
Diffstat (limited to 'src/net/tmwa')
-rw-r--r-- | src/net/tmwa/network.cpp | 2 | ||||
-rw-r--r-- | src/net/tmwa/partyhandler.cpp | 1 | ||||
-rw-r--r-- | src/net/tmwa/partyhandler.h | 1 | ||||
-rw-r--r-- | src/net/tmwa/playerhandler.cpp | 4 |
4 files changed, 5 insertions, 3 deletions
diff --git a/src/net/tmwa/network.cpp b/src/net/tmwa/network.cpp index 6e9e367c0..b8ba7554e 100644 --- a/src/net/tmwa/network.cpp +++ b/src/net/tmwa/network.cpp @@ -236,7 +236,7 @@ void Network::dispatchMessages() MessageHandlerIterator iter = mMessageHandlers.find(msg.getId()); if (msg.getLength() == 0) - logger->error("Zero length packet received. Exiting."); + logger->safeError("Zero length packet received. Exiting."); if (iter != mMessageHandlers.end()) { diff --git a/src/net/tmwa/partyhandler.cpp b/src/net/tmwa/partyhandler.cpp index 7f942a206..b8f3a07e1 100644 --- a/src/net/tmwa/partyhandler.cpp +++ b/src/net/tmwa/partyhandler.cpp @@ -1,6 +1,7 @@ /* * The ManaPlus Client * Copyright (C) 2008 Lloyd Bryant <lloyd_bryant@netzero.net> + * Copyright (C) 2011-2012 The ManaPlus Developers * * This file is part of The ManaPlus Client. * diff --git a/src/net/tmwa/partyhandler.h b/src/net/tmwa/partyhandler.h index 4d727a986..eb3f68a70 100644 --- a/src/net/tmwa/partyhandler.h +++ b/src/net/tmwa/partyhandler.h @@ -1,6 +1,7 @@ /* * The ManaPlus Client * Copyright (C) 2008 Lloyd Bryant <lloyd_bryant@netzero.net> + * Copyright (C) 2011-2012 The ManaPlus Developers * * This file is part of The ManaPlus Client. * diff --git a/src/net/tmwa/playerhandler.cpp b/src/net/tmwa/playerhandler.cpp index bfe9eea42..a63af770a 100644 --- a/src/net/tmwa/playerhandler.cpp +++ b/src/net/tmwa/playerhandler.cpp @@ -229,7 +229,7 @@ void PlayerHandler::processOnlineList(Net::MessageIn &msg) return; } - char *start = (char*)msg.readBytes(size); + char *start = reinterpret_cast<char*>(msg.readBytes(size)); if (!start) return; @@ -265,7 +265,7 @@ void PlayerHandler::processOnlineList(Net::MessageIn &msg) gender = GENDER_FEMALE; } } - arr.push_back(new OnlinePlayer((char*)buf, + arr.push_back(new OnlinePlayer(static_cast<char*>(buf), status, level, gender, ver)); buf += strlen(buf) + 1; } |