Procházet zdrojové kódy

Fixed incorrect file size returned

According to
https://msdn.microsoft.com/en-us/library/windows/desktop/aa365740%28v=vs.85%29.aspx
to return the actual file size you need to use the high and low file
size.
Nathan Bowhay před 11 roky
rodič
revize
32e3678000
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      Engine/source/platformWin32/winFileio.cpp

+ 1 - 1
Engine/source/platformWin32/winFileio.cpp

@@ -998,7 +998,7 @@ S32 Platform::getFileSize(const char *pFilePath)
       return -1;
 
    // must be a real file then
-   return findData.nFileSizeLow;
+   return ((findData.nFileSizeHigh * (MAXDWORD+1)) + findData.nFileSizeLow);
 }