- oops, nullptr check

This commit is contained in:
Rachael Alexanderson 2023-02-01 10:23:30 -05:00
parent 33b217bcc9
commit 82b7e93d26

View file

@ -393,7 +393,7 @@ level_info_t *level_info_t::CheckLevelRedirect ()
if (RedirectCVAR != NAME_None)
{
auto var = FindCVar(RedirectCVAR.GetChars(), NULL);
if ((var->GetRealType() == CVAR_Bool) && !(var->GetFlags() & CVAR_IGNORE)) // only check Bool cvars that are currently defined
if (var && (var->GetRealType() == CVAR_Bool) && !(var->GetFlags() & CVAR_IGNORE)) // only check Bool cvars that are currently defined
{
if (var->GetFlags() & CVAR_USERINFO)
{