From 0a84c61c39da51a5f141b7b974250a06c96735bb Mon Sep 17 00:00:00 2001 From: irungentoo Date: Sun, 24 Nov 2013 14:35:47 -0500 Subject: [PATCH] Fixed bug with group chats. --- toxcore/group_chats.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/toxcore/group_chats.c b/toxcore/group_chats.c index 7e18a334..b551a1fd 100644 --- a/toxcore/group_chats.c +++ b/toxcore/group_chats.c @@ -437,7 +437,8 @@ static int handle_data(Group_Chat *chat, uint8_t *data, uint32_t len) int peernum = peer_in_chat(chat, data); if (peernum == -1) { /*NOTE: This is just for testing and will be removed later.*/ - peernum = addpeer(chat, data); + if (data[crypto_box_PUBLICKEYBYTES + sizeof(uint32_t)] != GROUP_CHAT_QUIT) + peernum = addpeer(chat, data); } if (peernum == -1)