mirror of
https://github.com/etlegacy/Update-Installer.git
synced 2025-01-22 07:21:13 +00:00
Fix test for return value of GetCurrentDirectory() on Windows.
GetCurrentDirectory() returns zero on error or the length of the path otherwise.
This commit is contained in:
parent
61c717e6d6
commit
4d1dbe8059
1 changed files with 1 additions and 1 deletions
|
@ -543,7 +543,7 @@ std::string FileUtils::getcwd() throw (IOException)
|
|||
return std::string(path);
|
||||
#else
|
||||
char path[MAX_PATH];
|
||||
if (GetCurrentDirectory(MAX_PATH,path) != 0)
|
||||
if (GetCurrentDirectory(MAX_PATH,path) == 0)
|
||||
{
|
||||
throw FileUtils::IOException("Failed to get current directory");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue