summaryrefslogtreecommitdiffstats
path: root/source/ClientHandle.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--source/ClientHandle.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/ClientHandle.cpp b/source/ClientHandle.cpp
index 23a34d7bc..e1ade39e7 100644
--- a/source/ClientHandle.cpp
+++ b/source/ClientHandle.cpp
@@ -898,14 +898,15 @@ void cClientHandle::HandlePlaceBlock(int a_BlockX, int a_BlockY, int a_BlockZ, c
void cClientHandle::HandleChat(const AString & a_Message)
{
- if (!cRoot::Get()->GetServer()->Command(*this, a_Message))
+ AString Message(a_Message);
+ if (!cRoot::Get()->GetServer()->Command(*this, Message))
{
AString Msg;
Printf(Msg, "<%s%s%s> %s",
m_Player->GetColor().c_str(),
m_Player->GetName().c_str(),
cChatColor::White.c_str(),
- a_Message.c_str()
+ Message.c_str()
);
m_Player->GetWorld()->BroadcastChat(Msg);
}