mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-17 18:40:02 +00:00
filesystem: disable XASH_REDUCE_FD where it not needed, fix null pointer deference
This commit is contained in:
parent
7ad658ee3a
commit
68472f90eb
@ -64,8 +64,6 @@ GNU General Public License for more details.
|
|||||||
#define ZIP_LOAD_NO_FILES 5
|
#define ZIP_LOAD_NO_FILES 5
|
||||||
#define ZIP_LOAD_CORRUPTED 6
|
#define ZIP_LOAD_CORRUPTED 6
|
||||||
|
|
||||||
#define XASH_REDUCE_FD
|
|
||||||
|
|
||||||
typedef struct stringlist_s
|
typedef struct stringlist_s
|
||||||
{
|
{
|
||||||
// maxstrings changes as needed, causing reallocation of strings[] array
|
// maxstrings changes as needed, causing reallocation of strings[] array
|
||||||
@ -168,7 +166,7 @@ static void FS_EnsureOpenFile( file_t *file )
|
|||||||
if( fs_last_readfile == file )
|
if( fs_last_readfile == file )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if( !file->backup_path )
|
if( file && !file->backup_path )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if( fs_last_readfile && (fs_last_readfile->handle != -1) )
|
if( fs_last_readfile && (fs_last_readfile->handle != -1) )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user