https://git.reactos.org/?p=reactos.git;a=commitdiff;h=880252fd463233fce20dda...
commit 880252fd463233fce20ddacf77d561a808fd6397 Author: Katayama Hirofumi MZ katayama.hirofumi.mz@gmail.com AuthorDate: Fri Mar 19 08:30:10 2021 +0900 Commit: Katayama Hirofumi MZ katayama.hirofumi.mz@gmail.com CommitDate: Fri Mar 19 08:30:10 2021 +0900
[SHELL32] Fix assertion failure in CDirectoryWatcher.cpp
CORE-17511 --- dll/win32/shell32/shelldesktop/CDirectoryWatcher.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/dll/win32/shell32/shelldesktop/CDirectoryWatcher.cpp b/dll/win32/shell32/shelldesktop/CDirectoryWatcher.cpp index 1e4a7015287..d5056a64faa 100644 --- a/dll/win32/shell32/shelldesktop/CDirectoryWatcher.cpp +++ b/dll/win32/shell32/shelldesktop/CDirectoryWatcher.cpp @@ -162,8 +162,11 @@ void CDirectoryWatcher::ProcessNotification() // convert to long pathname if it contains '~' if (StrChrW(szPath, L'~') != NULL) { - GetLongPathNameW(szPath, szName, _countof(szName)); - lstrcpynW(szPath, szName, _countof(szPath)); + if (GetLongPathNameW(szPath, szName, _countof(szName)) && + !PathIsRelativeW(szName)) + { + lstrcpynW(szPath, szName, _countof(szPath)); + } }
// convert action to event