mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
filesystem: dir: fix possible null dereference
This commit is contained in:
@@ -471,6 +471,9 @@ static file_t *FS_OpenFile_DIR( searchpath_t *search, const char *filename, cons
|
||||
|
||||
Q_snprintf( path, sizeof( path ), "%s%s", search->filename, filename );
|
||||
f = FS_SysOpen( path, mode );
|
||||
if( !f )
|
||||
return NULL;
|
||||
|
||||
f->searchpath = search;
|
||||
|
||||
return f;
|
||||
|
||||
Reference in New Issue
Block a user