mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
public: explicitly cast chars to bytes in ctype functions
This commit is contained in:
@@ -929,12 +929,12 @@ void COM_TrimSpace( char *dst, const char *src, size_t size )
|
||||
return;
|
||||
|
||||
// remove spaces from the start
|
||||
for( ; *src && isspace( *src ); src++ );
|
||||
for( ; *src && isspace((byte)*src ); src++ );
|
||||
|
||||
int len = Q_strlen( src );
|
||||
|
||||
// remove spaces from the end
|
||||
for( ; len > 0 && isspace( src[len - 1] ); len-- );
|
||||
for( ; len > 0 && isspace((byte)src[len - 1] ); len-- );
|
||||
|
||||
if( len > 0 )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user