diff --git a/src/utils/filesystem_path.cpp b/src/utils/filesystem_path.cpp index d15ad7a192..8e00c33a61 100644 --- a/src/utils/filesystem_path.cpp +++ b/src/utils/filesystem_path.cpp @@ -114,7 +114,7 @@ class FilesystemPathImplWindows : public FilesystemPathImpl subpaths.clear(); HANDLE hFnd = FindFirstFile(examineDir.c_str(), &ffd); - if (hFnd == reinterpret_cast(-1)) + if (hFnd == INVALID_HANDLE_VALUE) return false; do @@ -142,7 +142,7 @@ class FilesystemPathImplWindows : public FilesystemPathImpl virtual bool isFile() override { WIN32_FIND_DATA ffd; - if (FindFirstFile(_path.c_str(), &ffd) == reinterpret_cast(-1)) + if (FindFirstFile(_path.c_str(), &ffd) == INVALID_HANDLE_VALUE) return false; return !(ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY); @@ -151,7 +151,7 @@ class FilesystemPathImplWindows : public FilesystemPathImpl virtual bool isDirectory() override { WIN32_FIND_DATA ffd; - if (FindFirstFile(_path.c_str(), &ffd) == reinterpret_cast(-1)) + if (FindFirstFile(_path.c_str(), &ffd) == INVALID_HANDLE_VALUE) return false; return ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY;