Skip to content

Commit

Permalink
Remove unused COM_LoadZoneFile
Browse files Browse the repository at this point in the history
  • Loading branch information
andrei-drexler committed Jul 14, 2024
1 parent 3ff9497 commit 5cda0de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 13 deletions.
13 changes: 2 additions & 11 deletions Quake/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -1992,9 +1992,8 @@ Filename are reletive to the quake directory.
Allways appends a 0 byte.
============
*/
#define LOADFILE_ZONE 0
#define LOADFILE_HUNK 1
#define LOADFILE_MALLOC 2
#define LOADFILE_HUNK 0
#define LOADFILE_MALLOC 1

byte *COM_LoadFile (const char *path, int usehunk, unsigned int *path_id)
{
Expand All @@ -2018,9 +2017,6 @@ byte *COM_LoadFile (const char *path, int usehunk, unsigned int *path_id)
case LOADFILE_HUNK:
buf = (byte *) Hunk_AllocName (len+1, base);
break;
case LOADFILE_ZONE:
buf = (byte *) Z_Malloc (len+1);
break;
case LOADFILE_MALLOC:
buf = (byte *) malloc (len+1);
break;
Expand All @@ -2046,11 +2042,6 @@ byte *COM_LoadHunkFile (const char *path, unsigned int *path_id)
return COM_LoadFile (path, LOADFILE_HUNK, path_id);
}

byte *COM_LoadZoneFile (const char *path, unsigned int *path_id)
{
return COM_LoadFile (path, LOADFILE_ZONE, path_id);
}

// returns malloc'd memory
byte *COM_LoadMallocFile (const char *path, unsigned int *path_id)
{
Expand Down
2 changes: 0 additions & 2 deletions Quake/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -407,8 +407,6 @@ void COM_CloseFile (int h);
// procedures differ by their buffer allocation method.
byte *COM_LoadHunkFile (const char *path, unsigned int *path_id);
// allocates the buffer on the hunk.
byte *COM_LoadZoneFile (const char *path, unsigned int *path_id);
// allocates the buffer on the zone.
byte *COM_LoadMallocFile (const char *path, unsigned int *path_id);
// allocates the buffer on the system mem (malloc).

Expand Down

0 comments on commit 5cda0de

Please sign in to comment.