mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2024-12-26 14:55:30 +03:00
Debug assertion on SquirrelVM::GetValue()
This commit is contained in:
parent
da2315cfe7
commit
e843aed912
@ -2970,6 +2970,14 @@ int SquirrelVM::GetKeyValue(HSCRIPT hScope, int nIterator, ScriptVariant_t* pKey
|
|||||||
|
|
||||||
bool SquirrelVM::GetValue(HSCRIPT hScope, const char* pszKey, ScriptVariant_t* pValue)
|
bool SquirrelVM::GetValue(HSCRIPT hScope, const char* pszKey, ScriptVariant_t* pValue)
|
||||||
{
|
{
|
||||||
|
#ifdef _DEBUG
|
||||||
|
AssertMsg( pszKey, "FATAL: cannot get NULL" );
|
||||||
|
|
||||||
|
// Don't crash on debug
|
||||||
|
if ( !pszKey )
|
||||||
|
return GetValue( hScope, ScriptVariant_t(0), pValue );
|
||||||
|
#endif
|
||||||
|
|
||||||
SquirrelSafeCheck safeCheck(vm_);
|
SquirrelSafeCheck safeCheck(vm_);
|
||||||
|
|
||||||
Assert(pValue);
|
Assert(pValue);
|
||||||
|
Loading…
Reference in New Issue
Block a user