Commit c8e28023 authored by Alexandre Julliard's avatar Alexandre Julliard

comdlg32: Fix path validation of UNC paths in the file dialog.

parent 757325bf
......@@ -2454,11 +2454,16 @@ int FILEDLG95_ValidatePathAction(LPWSTR lpstrPathAndFile, IShellFolder **ppsf,
LPWSTR p;
lstrcpyW(lpwstrTemp, lpszTemp);
if (lpszTemp == lpstrPathAndFile && (p = PathSkipRootW(lpwstrTemp)))
{
*p = 0;
}
else
{
p = PathFindNextComponentW(lpwstrTemp);
if (!p) break; /* end of path */
*p = 0;
}
lpszTemp = lpszTemp + lstrlenW(lpwstrTemp);
/* There are no wildcards when OFN_NOVALIDATE is set */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment