]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - fs.c
Added a mempool parameter to FS_LoadFile
[xonotic/darkplaces.git] / fs.c
diff --git a/fs.c b/fs.c
index cebf3e4c2b3013d69e30e1d7f78715800eddb84b..093d0ac9ad3a7cec37d5bd7d803d6d9efaf3e164 100644 (file)
--- a/fs.c
+++ b/fs.c
@@ -1719,7 +1719,7 @@ Filename are relative to the quake directory.
 Always appends a 0 byte.
 ============
 */
 Always appends a 0 byte.
 ============
 */
-qbyte *FS_LoadFile (const char *path, qboolean quiet)
+qbyte *FS_LoadFile (const char *path, mempool_t *pool, qboolean quiet)
 {
        qfile_t *h;
        qbyte *buf;
 {
        qfile_t *h;
        qbyte *buf;
@@ -1729,7 +1729,7 @@ qbyte *FS_LoadFile (const char *path, qboolean quiet)
        if (!h)
                return NULL;
 
        if (!h)
                return NULL;
 
-       buf = Mem_Alloc(tempmempool, fs_filesize+1);
+       buf = Mem_Alloc(pool, fs_filesize+1);
        if (!buf)
                Sys_Error ("FS_LoadFile: not enough available memory for %s (size %i)", path, fs_filesize);
 
        if (!buf)
                Sys_Error ("FS_LoadFile: not enough available memory for %s (size %i)", path, fs_filesize);