mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-07 11:14:58 -06:00
4.52 beta
This commit is contained in:
committed by
Kornel Lesiński
parent
d14d4dcdef
commit
33ccab7e72
@@ -214,9 +214,12 @@ bool MyCreateDirectory(LPCTSTR pathName)
|
||||
if (::CreateDirectory(pathName, NULL))
|
||||
return true;
|
||||
#ifdef WIN_LONG_PATH2
|
||||
UString longPath;
|
||||
if (GetLongPath(pathName, longPath))
|
||||
return BOOLToBool(::CreateDirectoryW(longPath, NULL));
|
||||
if (::GetLastError() != ERROR_ALREADY_EXISTS)
|
||||
{
|
||||
UString longPath;
|
||||
if (GetLongPath(pathName, longPath))
|
||||
return BOOLToBool(::CreateDirectoryW(longPath, NULL));
|
||||
}
|
||||
#endif
|
||||
return false;
|
||||
}
|
||||
@@ -227,11 +230,14 @@ bool MyCreateDirectory(LPCWSTR pathName)
|
||||
if (!g_IsNT)
|
||||
return MyCreateDirectory(GetSysPath(pathName));
|
||||
if (::CreateDirectoryW(pathName, NULL))
|
||||
return true;
|
||||
return true;
|
||||
#ifdef WIN_LONG_PATH
|
||||
UString longPath;
|
||||
if (GetLongPath(pathName, longPath))
|
||||
return BOOLToBool(::CreateDirectoryW(longPath, NULL));
|
||||
if (::GetLastError() != ERROR_ALREADY_EXISTS)
|
||||
{
|
||||
UString longPath;
|
||||
if (GetLongPath(pathName, longPath))
|
||||
return BOOLToBool(::CreateDirectoryW(longPath, NULL));
|
||||
}
|
||||
#endif
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user