Index: /trunk/src/VBox/Runtime/common/zip/pkzipvfs.cpp
===================================================================
--- /trunk/src/VBox/Runtime/common/zip/pkzipvfs.cpp	(revision 51696)
+++ /trunk/src/VBox/Runtime/common/zip/pkzipvfs.cpp	(revision 51697)
@@ -314,13 +314,13 @@
     RTZIPPKZIPBASEOBJ       BaseObj;
     /** The number of (uncompressed) bytes in the file. */
-    RTFOFF                  cbFile;
+    uint64_t                cbFile;
     /** The current file position at uncompressed file data. */
-    RTFOFF                  offFile;
+    uint64_t                offFile;
     /** The start position of the compressed data in the hVfsIos. */
-    RTFOFF                  offCompStart;
+    uint64_t                offCompStart;
     /** The current position for decompressing bytes in the hVfsIos. */
-    RTFOFF                  offComp;
+    uint64_t                offComp;
     /** The number of compressed bytes starting at offCompStart. */
-    RTFOFF                  cbComp;
+    uint64_t                cbComp;
     /** Set if we have to pass the type function the next time the input
      * function is called. */
@@ -355,7 +355,7 @@
 
     /** The offset of the first Central Directory header. */
-    RTFOFF                  offFirstCdh;
+    uint64_t                offFirstCdh;
     /** The offset of the next Central Directory header. */
-    RTFOFF                  offNextCdh;
+    uint64_t                offNextCdh;
 
     /** Size of the central directory. */
@@ -436,5 +436,5 @@
  * Return the offset of the Local File Header.
  */
-static RTFOFF rtZipPkzipReaderOffLocalHeader(PRTZIPPKZIPREADER pThis)
+static uint64_t rtZipPkzipReaderOffLocalHeader(PRTZIPPKZIPREADER pThis)
 {
     if (pThis->fZip64Ex && pThis->cdh.offLocalFileHeader == -1U)
@@ -448,5 +448,5 @@
  * Return the uncompressed object size.
  */
-static RTFOFF rtZipPkzipReaderUncompressed(PRTZIPPKZIPREADER pThis)
+static uint64_t rtZipPkzipReaderUncompressed(PRTZIPPKZIPREADER pThis)
 {
     if (pThis->fZip64Ex && pThis->cdh.cbUncompressed == -1U)
@@ -460,5 +460,5 @@
  * Return the compressed object size.
  */
-static RTFOFF rtZipPkzipReaderCompressed(PRTZIPPKZIPREADER pThis)
+static uint64_t rtZipPkzipReaderCompressed(PRTZIPPKZIPREADER pThis)
 {
     if (pThis->fZip64Ex && pThis->cdh.cbCompressed == -1U)
@@ -473,5 +473,5 @@
  */
 static int rtZipPkzipParseCentrDirHeaderExtra(PRTZIPPKZIPREADER pThis, uint8_t *pu8Buf, size_t cb,
-                                              RTZIPPKZIP_COMP_METHOD *penmCompMethod, PRTFOFF pcbCompressed)
+                                              RTZIPPKZIP_COMP_METHOD *penmCompMethod, uint64_t *pcbCompressed)
 {
     int rc = RTStrCopyEx(pThis->szName, sizeof(pThis->szName), (const char*)pu8Buf, pThis->cdh.cbFilename);
@@ -582,8 +582,8 @@
  * Directory.
  */
-static int rtZipPkzipFssIosReadLfh(PRTZIPPKZIPFSSTREAM pThis, RTFOFF *poffStartData)
+static int rtZipPkzipFssIosReadLfh(PRTZIPPKZIPFSSTREAM pThis, uint64_t *poffStartData)
 {
     RTZIPPKZIPLOCALFILEHDR lfh;
-    RTFOFF offLocalFileHeader = rtZipPkzipReaderOffLocalHeader(&pThis->PkzipReader);
+    uint64_t offLocalFileHeader = rtZipPkzipReaderOffLocalHeader(&pThis->PkzipReader);
     int rc = RTVfsIoStrmReadAt(pThis->hVfsIos, offLocalFileHeader,
                                &lfh, sizeof(lfh) - 1, true /*fBlocking*/, NULL);
@@ -614,10 +614,10 @@
  * Scan the current Central Directory Header.
  */
-static int rtZipPkzipFssIosReadCdh(PRTZIPPKZIPFSSTREAM pThis, RTFOFF *poffStartData,
-                                    RTZIPPKZIP_COMP_METHOD *penmCompMethod, PRTFOFF pcbCompressed)
+static int rtZipPkzipFssIosReadCdh(PRTZIPPKZIPFSSTREAM pThis, uint64_t *poffStartData,
+                                    RTZIPPKZIP_COMP_METHOD *penmCompMethod, uint64_t *pcbCompressed)
 {
     int rc;
 
-    RTFOFF offCd = pThis->offNextCdh - pThis->offFirstCdh;
+    uint64_t offCd = pThis->offNextCdh - pThis->offFirstCdh;
     if (   pThis->iCentrDirEntry < pThis->cCentrDirEntries
         || offCd + sizeof(RTZIPPKZIPCENTRDIRHDR) - 1 <= pThis->cbCentrDir)
@@ -688,7 +688,7 @@
     /* maximum size of EOCD comment 2^16-1 */
     const size_t cbHdrMax = 0xffff + sizeof(RTZIPPKZIPENDOFCENTRDIRREC) - 1;
-    RTFOFF offMin = cbFile >= cbHdrMax ? cbFile - cbHdrMax : 0;
-
-    RTFOFF off = cbFile - cbBuf;
+    uint64_t offMin = cbFile >= cbHdrMax ? cbFile - cbHdrMax : 0;
+
+    uint64_t off = cbFile - cbBuf;
     while (off >= offMin)
     {
@@ -709,5 +709,5 @@
                 {
                     /* sanity check */
-                    if (off + RT_UOFFSETOF(RTZIPPKZIPENDOFCENTRDIRREC, u8Comment) + eocd.cbComment == cbFile)
+                    if (off + RT_OFFSETOF(RTZIPPKZIPENDOFCENTRDIRREC, u8Comment) + eocd.cbComment == cbFile)
                     {
                         pThis->offFirstCdh = eocd.offCentrDir;
@@ -896,5 +896,5 @@
     if (off < 0)
         off = pThis->offFile;
-    if (off >= pThis->cbFile)
+    if (off >= (RTFOFF)pThis->cbFile)
         return pcbRead ? VINF_EOF : VERR_EOF;
 
@@ -914,5 +914,5 @@
     if (   !pThis->pZip
         || !off
-        || off < pThis->offFile)
+        || off < (RTFOFF)pThis->offFile)
     {
         switch (pThis->enmCompMethod)
@@ -944,8 +944,8 @@
      * Skip bytes if necessary.
      */
-    if (off > pThis->offFile)
+    if (off > (RTFOFF)pThis->offFile)
     {
         uint8_t u8Buf[_1K];
-        while (off > pThis->offFile)
+        while (off > (RTFOFF)pThis->offFile)
         {
             size_t cbSkip = off - pThis->offFile;
@@ -1105,5 +1105,5 @@
     if (!pThis->PkzipReader.fHaveEocd)
         rc = rtZipPkzipFssIosReadEocb(pThis);
-    RTFOFF offData = 0;
+    uint64_t offData = 0;
 
     /*
@@ -1111,5 +1111,5 @@
      */
     RTZIPPKZIP_COMP_METHOD enmCompMethod = RTZIPPKZIP_COMP_METHOD_STORED;
-    RTFOFF cbCompressed = 0;
+    uint64_t cbCompressed = 0;
     if (RT_SUCCESS(rc))
         rc = rtZipPkzipFssIosReadCdh(pThis, &offData, &enmCompMethod, &cbCompressed);
