mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-18 19:10:37 +00:00
engine: fix buffer overflow in COM_ParseFile
This commit is contained in:
parent
0ce8d92f27
commit
e308281b0b
@ -510,8 +510,17 @@ skipwhite:
|
||||
data++;
|
||||
while( 1 )
|
||||
{
|
||||
c = (byte)*data++;
|
||||
if( c == '\"' || !c )
|
||||
c = (byte)*data;
|
||||
|
||||
// unexpected line end
|
||||
if( !c )
|
||||
{
|
||||
token[len] = 0;
|
||||
return data;
|
||||
}
|
||||
data++;
|
||||
|
||||
if( c == '\"' )
|
||||
{
|
||||
token[len] = 0;
|
||||
return data;
|
||||
|
Loading…
x
Reference in New Issue
Block a user