mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 12:23:31 +00:00
- Robert Horvath: Always limit destLen to MAX_PATH (modified to an if condition by me).
See issue #5861 for more details. svn path=/trunk/; revision=50543
This commit is contained in:
@@ -72,6 +72,9 @@ FilenameU2A_FitOrFail(
|
||||
{
|
||||
DWORD ret;
|
||||
|
||||
/* destLen should never exceed MAX_PATH */
|
||||
if (destLen > MAX_PATH) destLen = MAX_PATH;
|
||||
|
||||
ret = bIsFileApiAnsi? RtlUnicodeStringToAnsiSize(SourceU) : RtlUnicodeStringToOemSize(SourceU);
|
||||
/* ret incl. nullchar */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user