mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2025-01-12 14:57:56 +03:00
Fix CBaseEntity::ScriptGetKeyValue() returning cached string on invalid input
This commit is contained in:
parent
976eb23299
commit
a6f9d0a0e2
@ -10297,8 +10297,9 @@ bool CBaseEntity::ScriptAddOutput( const char *pszOutputName, const char *pszTar
|
|||||||
const char *CBaseEntity::ScriptGetKeyValue( const char *pszKeyName )
|
const char *CBaseEntity::ScriptGetKeyValue( const char *pszKeyName )
|
||||||
{
|
{
|
||||||
static char szValue[128];
|
static char szValue[128];
|
||||||
GetKeyValue( pszKeyName, szValue, sizeof(szValue) );
|
if ( GetKeyValue( pszKeyName, szValue, sizeof(szValue) ) )
|
||||||
return szValue;
|
return szValue;
|
||||||
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
Loading…
x
Reference in New Issue
Block a user