Fix crash on startup

This crashes on Linux as pKeyValuesData is NULL when deleteThis() is
invoked. This likely is caused by another issue, but fixing this here
seems good regardless.
This commit is contained in:
Alexander 'z33ky' Hirsch 2019-10-04 01:22:06 +02:00
parent 5b2547a6ff
commit 48fb4ab56c

View File

@ -134,11 +134,14 @@ void LoadHudTextures( CUtlDict< CHudTexture *, int >& list, const char *szFilena
pTemp = pTemp->GetNextKey();
}
}
}
// Failed for some reason. Delete the Key data and abort.
pKeyValuesData->deleteThis();
}
else
{
Warning( "Unable to read script %s.\n", szFilenameWithoutExtension );
}
}
//-----------------------------------------------------------------------------
// Purpose: