platform/win32.c
changeset 338 4f6d300bf1d7
parent 335 1d4720c018c3
child 362 ac8c846a0a66
--- a/platform/win32.c	Sat Jul 13 10:17:13 2002 +0000
+++ b/platform/win32.c	Sun Jul 14 15:11:39 2002 +0000
@@ -249,22 +249,22 @@
 } /* determineUserDir */
 
 
-static BOOL mediaInDrive(const char *driveLetter)
+static BOOL mediaInDrive(const char *drive)
 {
     UINT oldErrorMode;
-    DWORD dummyValue;
-    BOOL returnValue;
+    DWORD tmp;
+    BOOL retval;
 
     /* Prevent windows warning message to appear when checking media size */
     oldErrorMode = SetErrorMode(SEM_FAILCRITICALERRORS);
     
     /* If this function succeeds, there's media in the drive */
-    returnValue = GetDiskFreeSpace(driveLetter, &dummyValue, &dummyValue, &dummyValue, &dummyValue);
+    retval = GetVolumeInformation(drive, NULL, 0, NULL, NULL, &tmp, NULL, 0);
 
     /* Revert back to old windows error handler */
     SetErrorMode(oldErrorMode);
 
-    return(returnValue);
+    return(retval);
 } /* mediaInDrive */