Fix for ZIP code in engine, incorrectly reporting Zip Error for .PK3's

which were fine.


git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2921 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Lance 2008-02-13 14:09:02 +00:00
parent 4f755cf39e
commit fe4d6a80da

View file

@ -1026,6 +1026,7 @@ of the list so they override previous pack files.
static void *FSZIP_LoadZipFile (vfsfile_t *packhandle, char *desc)
{
int i;
int nextfileziphandle;
zipfile_t *zip;
packfile_t *newfiles;
@ -1055,7 +1056,11 @@ static void *FSZIP_LoadZipFile (vfsfile_t *packhandle, char *desc)
Q_strlwr(newfiles[i].name);
newfiles[i].filelen = file_info.uncompressed_size;
newfiles[i].filepos = file_info.c_offset;
if (unzGoToNextFile (zip->handle) != UNZ_OK)
nextfileziphandle = unzGoToNextFile (zip->handle);
if (nextfileziphandle == UNZ_END_OF_LIST_OF_FILE)
break;
else if (nextfileziphandle != UNZ_OK)
Con_Printf("Zip Error\n");
}