Skip to content

Commit

Permalink
Always validate clientNum in CL_ParseServerData().
Browse files Browse the repository at this point in the history
  • Loading branch information
skullernet committed Oct 1, 2022
1 parent 97f0ab2 commit ad90930
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/client/parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -631,12 +631,12 @@ static void CL_ParseServerData(void)
Com_SetColor(COLOR_ALT);
Com_Printf("%s\n", levelname);
Com_SetColor(COLOR_NONE);
}

// make sure clientNum is in range
if (!VALIDATE_CLIENTNUM(cl.clientNum)) {
Com_WPrintf("Serverdata has invalid playernum %d\n", cl.clientNum);
cl.clientNum = -1;
}
// make sure clientNum is in range
if (!VALIDATE_CLIENTNUM(cl.clientNum)) {
Com_WPrintf("Serverdata has invalid playernum %d\n", cl.clientNum);
cl.clientNum = -1;
}
}

Expand Down

0 comments on commit ad90930

Please sign in to comment.