- fix compilation with msvc
[reactos.git] / rosapps / fraginator / DriveVolume.cpp
index 3b0863f..be57628 100644 (file)
@@ -48,7 +48,7 @@ bool DriveVolume::Open (wstring Name)
     RootPath = Name.c_str();\r
     RootPath += L"\\";\r
 \r
-    Handle = CreateFile\r
+    Handle = CreateFileW\r
     (\r
         FileName,\r
         MAXIMUM_ALLOWED,                          // access\r
@@ -71,7 +71,7 @@ bool DriveVolume::Open (wstring Name)
         BOOL  Result;\r
 \r
         ReturnVal = true;\r
-        Result = GetVolumeInformation\r
+        Result = GetVolumeInformationW\r
         (\r
             RootPath.c_str(),\r
             VolName,\r
@@ -140,7 +140,7 @@ bool DriveVolume::ObtainInfo (void)
     DWORD FreeClusters;\r
     DWORD TotalClusters;\r
 \r
-    Result = GetDiskFreeSpace\r
+    Result = GetDiskFreeSpaceW\r
     (\r
         RootPath.c_str(),\r
         &SectorsPerCluster,\r
@@ -155,7 +155,7 @@ bool DriveVolume::ObtainInfo (void)
 \r
     VolInfo.ClusterSize = SectorsPerCluster * BytesPerSector;\r
 \r
-    Result = GetDiskFreeSpaceEx\r
+    Result = GetDiskFreeSpaceExW\r
     (\r
         RootPath.c_str(),\r
         (PULARGE_INTEGER)&nan,\r
@@ -367,7 +367,7 @@ uint32 DriveVolume::RemoveDBFile (uint32 Indice)
 \r
 bool DriveVolume::ScanDirectory (wstring DirPrefix, ScanCallback Callback, void *UserData)\r
 {\r
-    WIN32_FIND_DATA FindData;\r
+    WIN32_FIND_DATAW FindData;\r
     HANDLE          FindHandle;\r
     wstring          SearchString;\r
     uint32          DirIndice;\r
@@ -377,7 +377,7 @@ bool DriveVolume::ScanDirectory (wstring DirPrefix, ScanCallback Callback, void
     SearchString = DirPrefix;\r
     SearchString += L"*.*";\r
     ZeroMemory (&FindData, sizeof (FindData));\r
-    FindHandle = FindFirstFile (SearchString.c_str(), &FindData);\r
+    FindHandle = FindFirstFileW (SearchString.c_str(), &FindData);\r
 \r
     if (FindHandle == INVALID_HANDLE_VALUE)\r
         return (false);\r
@@ -460,7 +460,7 @@ bool DriveVolume::ScanDirectory (wstring DirPrefix, ScanCallback Callback, void
             ScanDirectory (Dir, Callback, UserData);\r
         }\r
 \r
-    } while (FindNextFile (FindHandle, &FindData) == TRUE);\r
+    } while (FindNextFileW (FindHandle, &FindData) == TRUE);\r
 \r
     FindClose (FindHandle);\r
     return (false);\r
@@ -497,7 +497,7 @@ bool DriveVolume::GetClusterInfo (FileInfo &Info, HANDLE &HandleResult)
 \r
     FullName = GetDBDir (Info.DirIndice) + Info.Name;\r
 \r
-    Handle = CreateFile\r
+    Handle = CreateFileW\r
     (\r
         FullName.c_str(),\r
         0, //GENERIC_READ,\r
@@ -688,7 +688,7 @@ bool DriveVolume::MoveFileDumb (uint32 FileIndice, uint64 NewLCN)
     */\r
 \r
     // Open file\r
-    FileHandle = CreateFile\r
+    FileHandle = CreateFileW\r
     (\r
         FullName.c_str (),\r
         GENERIC_READ,\r