From 9e30ffcdb7982d8dfeabbd33db9012b14011fa1b Mon Sep 17 00:00:00 2001 From: toaster Date: Thu, 13 Apr 2023 21:18:05 +0100 Subject: [PATCH] Got_KickCmd: Do not kick players with the server node from the server (this shut down the server previously !?) --- src/d_clisrv.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/src/d_clisrv.c b/src/d_clisrv.c index 3a6841085..c0393ec6a 100644 --- a/src/d_clisrv.c +++ b/src/d_clisrv.c @@ -3189,16 +3189,6 @@ static void Got_KickCmd(UINT8 **p, INT32 playernum) pnum = READUINT8(*p); msg = READUINT8(*p); - if (pnum == serverplayer && IsPlayerAdmin(playernum)) - { - CONS_Printf(M_GetText("Server is being shut down remotely. Goodbye!\n")); - - if (server) - COM_BufAddText("quit\n"); - - return; - } - if (msg == KICK_MSG_CUSTOM_BAN || msg == KICK_MSG_CUSTOM_KICK) { READSTRINGN(*p, reason, MAX_REASONLENGTH+1); @@ -3264,6 +3254,12 @@ static void Got_KickCmd(UINT8 **p, INT32 playernum) } } + if (playernode[pnum] == servernode) + { + CONS_Printf(M_GetText("Ignoring kick attempt from %s on node %d (it's the server)\n"), player_names[playernum], servernode); + return; + } + //CONS_Printf("\x82%s ", player_names[pnum]); // Save bans here. Used to be split between here and the actual command, depending on