possible loop problems fix

This commit is contained in:
Václav Šmejkal 2024-02-21 21:35:13 +01:00
parent d30cd4f714
commit c2b9c7c57a
Signed by: ENGO150
GPG Key ID: 4A57E86482968843

View File

@ -753,7 +753,7 @@ void *why2_listen_server(void *socket)
if (read == NULL) continue;
}
if (strncmp(read, server_uname, strlen(server_uname)) == 0 && strncmp(read + strlen(server_uname), ": code", 6) == 0) //CODE WAS SENT
if ((strncmp(read, server_uname, strlen(server_uname)) == 0 && strncmp(read + strlen(server_uname), ": code", 6) == 0) && !continuing) //CODE WAS SENT
{
if (strcmp(read + strlen(server_uname) + 2, WHY2_CHAT_CODE_SSQC) == 0) //SERVER BROKE UP WITH YOU
{