From 0703abf5cd1ca3f94942483df4592429cf091800 Mon Sep 17 00:00:00 2001 From: Brandon Wright Date: Fri, 11 Nov 2016 14:59:18 -0600 Subject: [PATCH] Fix API incompatibility between minizip versions. --- loadzip.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/loadzip.cpp b/loadzip.cpp index dab25045..d3168939 100644 --- a/loadzip.cpp +++ b/loadzip.cpp @@ -261,7 +261,7 @@ bool8 LoadZip (const char *zipname, uint32 *TotalFileSize, uint8 *buffer) uint8 *ptr = buffer; bool8 more = FALSE; - unzLocateFile(file, filename, 1); + unzLocateFile(file, filename, NULL); unzGetCurrentFileInfo(file, &info, filename, 128, NULL, 0, NULL, 0); if (unzOpenCurrentFile(file) != UNZ_OK) @@ -283,7 +283,7 @@ bool8 LoadZip (const char *zipname, uint32 *TotalFileSize, uint8 *buffer) return (FALSE); } - if (l <= 0 || l != FileSize) + if (l <= 0 || l != (int) FileSize) { unzClose(file); return (FALSE); @@ -321,7 +321,7 @@ bool8 LoadZip (const char *zipname, uint32 *TotalFileSize, uint8 *buffer) if (more) { - if (unzLocateFile(file, filename, 1) != UNZ_OK || + if (unzLocateFile(file, filename, NULL) != UNZ_OK || unzGetCurrentFileInfo(file, &info, filename, 128, NULL, 0, NULL, 0) != UNZ_OK || unzOpenCurrentFile(file) != UNZ_OK) break;