small cleanup and bugfix for zlib->abail_zlip
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1576 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
277d0b6960
commit
cdb82f3316
1 changed files with 28 additions and 52 deletions
|
@ -411,7 +411,7 @@ void *com_pathforfile; //fread and stuff is preferable if null
|
||||||
|
|
||||||
#define ZEXPORT VARGS
|
#define ZEXPORT VARGS
|
||||||
|
|
||||||
#ifdef ZLIB
|
#ifdef AVAIL_ZLIB
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#pragma comment( lib, "../libs/zlib.lib" )
|
#pragma comment( lib, "../libs/zlib.lib" )
|
||||||
#endif
|
#endif
|
||||||
|
@ -1680,7 +1680,7 @@ void COM_AddGameDirectory (char *dir, unsigned int loadstuff)
|
||||||
if (loadstuff & 2)
|
if (loadstuff & 2)
|
||||||
COM_AddDataFiles("pak", &packfilefuncs);//q1/hl/h2/q2
|
COM_AddDataFiles("pak", &packfilefuncs);//q1/hl/h2/q2
|
||||||
//pk2s never existed.
|
//pk2s never existed.
|
||||||
#ifdef ZLIB
|
#ifdef AVAIL_ZLIB
|
||||||
if (loadstuff & 4)
|
if (loadstuff & 4)
|
||||||
COM_AddDataFiles("pk3", &zipfilefuncs); //q3 + offspring
|
COM_AddDataFiles("pk3", &zipfilefuncs); //q3 + offspring
|
||||||
if (loadstuff & 8)
|
if (loadstuff & 8)
|
||||||
|
@ -1790,30 +1790,6 @@ void COM_Gamedir (char *dir)
|
||||||
while (com_searchpaths != com_base_searchpaths)
|
while (com_searchpaths != com_base_searchpaths)
|
||||||
{
|
{
|
||||||
com_searchpaths->funcs->ClosePath(com_searchpaths->handle);
|
com_searchpaths->funcs->ClosePath(com_searchpaths->handle);
|
||||||
/*
|
|
||||||
switch(com_searchpaths->type)
|
|
||||||
{
|
|
||||||
case SPT_PACK:
|
|
||||||
fclose (com_searchpaths->u.pack->handle);
|
|
||||||
Z_Free (com_searchpaths->u.pack->files);
|
|
||||||
#ifdef HASH_FILESYSTEM
|
|
||||||
Z_Free (com_searchpaths->u.pack->hash.bucket);
|
|
||||||
#endif
|
|
||||||
Z_Free (com_searchpaths->u.pack);
|
|
||||||
break;
|
|
||||||
#ifdef ZLIB
|
|
||||||
case SPT_ZIP:
|
|
||||||
unzClose(com_searchpaths->u.zip->handle);
|
|
||||||
Z_Free (com_searchpaths->u.zip->files);
|
|
||||||
#ifdef HASH_FILESYSTEM
|
|
||||||
Z_Free (com_searchpaths->u.zip->hash.bucket);
|
|
||||||
#endif
|
|
||||||
Z_Free (com_searchpaths->u.zip);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
case SPT_OS:
|
|
||||||
break;
|
|
||||||
}*/
|
|
||||||
next = com_searchpaths->next;
|
next = com_searchpaths->next;
|
||||||
Z_Free (com_searchpaths);
|
Z_Free (com_searchpaths);
|
||||||
com_searchpaths = next;
|
com_searchpaths = next;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue