зеркало из https://github.com/mozilla/gecko-dev.git
Fixing bug 383769. nsLocalFile::EnsureShortPath should check if GetShortPathNameW failed. r=benjamin@smedbergs.us
This commit is contained in:
Родитель
dde1dded06
Коммит
c16e1a5d68
|
@ -2929,7 +2929,8 @@ nsLocalFile::EnsureShortPath()
|
|||
WCHAR thisshort[MAX_PATH];
|
||||
DWORD thisr = ::GetShortPathNameW(mWorkingPath.get(), thisshort,
|
||||
sizeof(thisshort));
|
||||
if (thisr < sizeof(thisshort))
|
||||
// If an error occured (thisr == 0) thisshort is uninitialized memory!
|
||||
if (thisr != 0 && thisr < sizeof(thisshort))
|
||||
mShortWorkingPath.Assign(thisshort);
|
||||
else
|
||||
mShortWorkingPath.Assign(mWorkingPath);
|
||||
|
|
Загрузка…
Ссылка в новой задаче