mirror of
https://github.com/reactos/reactos.git
synced 2026-06-05 11:12:56 +08:00
[SHELL32] Fix a potential buffer overrun.
Patch by Kudratov Olimjon. CORE-8545
This commit is contained in:
@@ -519,7 +519,7 @@ static LPWSTR Stream_LoadPath(LPCSTR p, DWORD maxlen)
|
||||
{
|
||||
UINT len = 0;
|
||||
|
||||
while (p[len] && len < maxlen)
|
||||
while (len < maxlen && p[len])
|
||||
len++;
|
||||
|
||||
UINT wlen = MultiByteToWideChar(CP_ACP, 0, p, len, NULL, 0);
|
||||
|
||||
Reference in New Issue
Block a user