Commit 44da2475 authored by Louis. Lenders's avatar Louis. Lenders Committed by Alexandre Julliard

kernel32: Print an error instead of crashing in GetLongPathNameW if shortpath=0.

parent 353cd81c
......@@ -294,7 +294,7 @@ DWORD WINAPI GetLongPathNameW( LPCWSTR shortpath, LPWSTR longpath, DWORD longlen
LPCWSTR p;
DWORD sp = 0, lp = 0;
DWORD tmplen;
BOOL unixabsolute = (shortpath[0] == '/');
BOOL unixabsolute;
WIN32_FIND_DATAW wfd;
HANDLE goit;
......@@ -318,6 +318,8 @@ DWORD WINAPI GetLongPathNameW( LPCWSTR shortpath, LPWSTR longpath, DWORD longlen
return strlenW(longpath);
}
unixabsolute = (shortpath[0] == '/');
/* check for drive letter */
if (!unixabsolute && shortpath[1] == ':' )
{
......
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