Fixed IsMapValid passing blank string to engine's IsMapValid which crashes some games.
This commit is contained in:
parent
08d83eb8da
commit
70e29d4f20
@ -1243,6 +1243,9 @@ static bool ResolveFuzzyMapName(const char *fuzzyName, char *outFullname, int si
|
|||||||
|
|
||||||
bool CHalfLife2::IsMapValid(const char *map)
|
bool CHalfLife2::IsMapValid(const char *map)
|
||||||
{
|
{
|
||||||
|
if (!map || !map[0])
|
||||||
|
return false;
|
||||||
|
|
||||||
bool ret = engine->IsMapValid(map);
|
bool ret = engine->IsMapValid(map);
|
||||||
#if SOURCE_ENGINE >= SE_LEFT4DEAD
|
#if SOURCE_ENGINE >= SE_LEFT4DEAD
|
||||||
if (!ret)
|
if (!ret)
|
||||||
|
Loading…
Reference in New Issue
Block a user