mirror of
https://github.com/ioquake/ioq3.git
synced 2024-11-10 07:11:46 +00:00
Fix potential buffer overflow caused by long tcMod args
Found by Coverity.
This commit is contained in:
parent
9c99cf29db
commit
eeeaf3f125
2 changed files with 4 additions and 4 deletions
|
@ -1010,8 +1010,8 @@ static qboolean ParseStage( shaderStage_t *stage, char **text )
|
|||
token = COM_ParseExt( text, qfalse );
|
||||
if ( token[0] == 0 )
|
||||
break;
|
||||
strcat( buffer, token );
|
||||
strcat( buffer, " " );
|
||||
Q_strcat( buffer, sizeof (buffer), token );
|
||||
Q_strcat( buffer, sizeof (buffer), " " );
|
||||
}
|
||||
|
||||
ParseTexMod( buffer, stage );
|
||||
|
|
|
@ -1265,8 +1265,8 @@ static qboolean ParseStage( shaderStage_t *stage, char **text )
|
|||
token = COM_ParseExt( text, qfalse );
|
||||
if ( token[0] == 0 )
|
||||
break;
|
||||
strcat( buffer, token );
|
||||
strcat( buffer, " " );
|
||||
Q_strcat( buffer, sizeof (buffer), token );
|
||||
Q_strcat( buffer, sizeof (buffer), " " );
|
||||
}
|
||||
|
||||
ParseTexMod( buffer, stage );
|
||||
|
|
Loading…
Reference in a new issue