mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-04-28 21:57:57 +03:00
Fixed a tiny mistake present in all mohaa versions, with a possible overflow in client index in PF_centerprintf and PF_locationprintf
This commit is contained in:
parent
4e38b803fb
commit
ff2e64a742
1 changed files with 2 additions and 2 deletions
|
@ -1298,7 +1298,7 @@ void PF_centerprintf( gentity_t *ent, const char *fmt, ... )
|
|||
va_list va;
|
||||
char msg[ 2048 ];
|
||||
|
||||
if( ent->s.number > svs.iNumClients )
|
||||
if( ent->s.number >= svs.iNumClients )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
@ -1324,7 +1324,7 @@ void PF_locationprintf( gentity_t *ent, int x, int y, const char *fmt, ... )
|
|||
va_list va;
|
||||
char msg[ 2048 ];
|
||||
|
||||
if( ent->s.number > svs.iNumClients )
|
||||
if( ent->s.number >= svs.iNumClients )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue