AMXX won't crash now on invalid plugin path
This commit is contained in:
parent
b4107e3523
commit
ca0a32a546
@ -43,7 +43,7 @@ CForward::CForward(const char *name, ForwardExecType et, int numParams, const Fo
|
|||||||
AMXForward *tmp = NULL;
|
AMXForward *tmp = NULL;
|
||||||
for (CPluginMngr::iterator iter = g_plugins.begin(); iter; ++iter)
|
for (CPluginMngr::iterator iter = g_plugins.begin(); iter; ++iter)
|
||||||
{
|
{
|
||||||
if (amx_FindPublic((*iter).getAMX(), name, &func) == AMX_ERR_NONE)
|
if ((*iter).isValid() && amx_FindPublic((*iter).getAMX(), name, &func) == AMX_ERR_NONE)
|
||||||
{
|
{
|
||||||
tmp = new AMXForward;
|
tmp = new AMXForward;
|
||||||
if (!tmp)
|
if (!tmp)
|
||||||
|
Loading…
Reference in New Issue
Block a user