mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2025-02-01 05:30:58 +00:00
Check if FS_LIstFiles() returned NULL.
This would have prevented the 7.44 release f*ckup. In practise this shoudl never happen, because there's always baseq2/ but you never know and it's better to be sure.
This commit is contained in:
parent
5ed882763a
commit
36d64aaefb
1 changed files with 5 additions and 0 deletions
|
@ -1837,6 +1837,11 @@ FS_ListMods(int *nummods)
|
|||
|
||||
dirchildren = FS_ListFiles(searchpath, &numdirchildren, 0, 0);
|
||||
|
||||
if (dirchildren == NULL)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
// iterate over the children of this Raw path (unless we've already got enough mods)
|
||||
for (int i = 0; i < numdirchildren && nmods < MAX_MODS; i++)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue