fixed ipaddr lookup not working for admins
fixed a bug where steam-based auth could override ip auth --HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40937
This commit is contained in:
parent
2e3c61c849
commit
eee7c78342
@ -156,10 +156,13 @@ void PlayerManager::RunAuthChecks()
|
||||
removed++;
|
||||
|
||||
/* Do admin lookups */
|
||||
AdminId id = g_Admins.FindAdminByIdentity("steam", authstr);
|
||||
if (id != INVALID_ADMIN_ID)
|
||||
if (pPlayer->GetAdminId() == INVALID_ADMIN_ID)
|
||||
{
|
||||
CheckSetAdmin(client, pPlayer, id);
|
||||
AdminId id = g_Admins.FindAdminByIdentity("steam", authstr);
|
||||
if (id != INVALID_ADMIN_ID)
|
||||
{
|
||||
CheckSetAdmin(client, pPlayer, id);
|
||||
}
|
||||
}
|
||||
|
||||
/* Send to extensions */
|
||||
@ -285,7 +288,7 @@ bool PlayerManager::OnClientConnect_Post(edict_t *pEntity, const char *pszName,
|
||||
*ptr = '\0';
|
||||
}
|
||||
|
||||
AdminId id = g_Admins.FindAdminByIdentity("ip", pPlayer->GetIPAddress());
|
||||
AdminId id = g_Admins.FindAdminByIdentity("ip", ip);
|
||||
if (id != INVALID_ADMIN_ID)
|
||||
{
|
||||
CheckSetAdmin(client, pPlayer, id);
|
||||
|
Loading…
Reference in New Issue
Block a user