(svn r23337) -Fix [FS#4826]: don't send chat messages to clients that haven't joined yet

This commit is contained in:
rubidium 2011-11-26 17:28:18 +00:00
parent 4cbd3f4c5d
commit 26eebf2203

View File

@ -702,6 +702,8 @@ NetworkRecvStatus ServerNetworkGameSocketHandler::SendCommand(const CommandPacke
*/
NetworkRecvStatus ServerNetworkGameSocketHandler::SendChat(NetworkAction action, ClientID client_id, bool self_send, const char *msg, int64 data)
{
if (this->status != STATUS_ACTIVE) return NETWORK_RECV_STATUS_OKAY;
Packet *p = new Packet(PACKET_SERVER_CHAT);
p->Send_uint8 (action);