Fixed a bug where handlers wouldn't work if they were in the 0th slot

This commit is contained in:
David Anderson 2006-03-29 22:42:03 +00:00
parent 414ecdfffa
commit 3783e34a70

View File

@ -647,7 +647,7 @@ int Handler::SetErrorHandler(const char *function)
error = amx_FindPublic(m_pAmx, function, &m_iErrFunc);
if (error != AMX_ERR_NONE && m_iErrFunc < 1)
if (error != AMX_ERR_NONE && m_iErrFunc < 0)
m_iErrFunc = -1;
return error;
@ -659,7 +659,7 @@ int Handler::SetModuleFilter(const char *function)
error = amx_FindPublic(m_pAmx, function, &m_iModFunc);
if (error != AMX_ERR_NONE && m_iModFunc < 1)
if (error != AMX_ERR_NONE && m_iModFunc < 0)
m_iModFunc = -1;
return error;
@ -695,7 +695,7 @@ const char *Handler::GetLastMsg()
int Handler::HandleModule(const char *module)
{
if (m_iModFunc < 1)
if (m_iModFunc < 0)
return 0;
/**