mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-17 18:40:02 +00:00
engine: common: lib_common: fix offset by one UB
This commit is contained in:
parent
58e95c7d6f
commit
fb0f184d6b
@ -410,11 +410,13 @@ char **COM_ConvertToLocalPlatform( EFunctionMangleType to, const char *from, siz
|
||||
|
||||
if( at ) len = (uint)( at - prev );
|
||||
else len = (uint)Q_strlen( prev );
|
||||
|
||||
Q_strncpy( symbols[i], prev, Q_min( len + 1, sizeof( symbols[i] )));
|
||||
prev = at + 1;
|
||||
|
||||
if( !at )
|
||||
break;
|
||||
|
||||
prev = at + 1;
|
||||
}
|
||||
|
||||
if( i == MAX_NESTED_NAMESPACES )
|
||||
|
Loading…
x
Reference in New Issue
Block a user