Fix empty message resulting in corrupted packets
authorunc0rr
Thu, 20 Jan 2011 21:32:39 +0300
changeset 4862 899b4e3d350a
parent 4861 91f889289a47
child 4863 5dcc108fa96a
Fix empty message resulting in corrupted packets
gameServer/HWProtoNEState.hs
--- a/gameServer/HWProtoNEState.hs	Thu Jan 20 01:49:20 2011 +0100
+++ b/gameServer/HWProtoNEState.hs	Thu Jan 20 21:32:39 2011 +0300
@@ -13,7 +13,7 @@
 
 handleCmd_NotEntered clID clients _ ["NICK", newNick]
     | not . null $ nick client = [ProtocolError "Nickname already chosen"]
-    | haveSameNick = [AnswerThisClient ["WARNING", "Nickname already in use"], ByeClient ""]
+    | haveSameNick = [AnswerThisClient ["WARNING", "Nickname already in use"], ByeClient "Nickname already in use"]
     | illegalName newNick = [ByeClient "Illegal nickname"]
     | otherwise =
         ModifyClient (\c -> c{nick = newNick}) :