mirror of
https://github.com/alliedmodders/amxmodx.git
synced 2025-01-12 06:48:04 +03:00
fixed possible overrun bug
This commit is contained in:
parent
6997c780d9
commit
0520c606ec
@ -390,15 +390,21 @@ reswitch:
|
||||
}
|
||||
case '%':
|
||||
*buf_p++ = static_cast<D>(ch);
|
||||
if (!llen)
|
||||
goto done;
|
||||
llen--;
|
||||
break;
|
||||
case '\0':
|
||||
*buf_p++ = static_cast<D>('%');
|
||||
if (!llen)
|
||||
goto done;
|
||||
llen--;
|
||||
goto done;
|
||||
break;
|
||||
default:
|
||||
*buf_p++ = static_cast<D>(ch);
|
||||
if (!llen)
|
||||
goto done;
|
||||
llen--;
|
||||
break;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user