[8823] removed ban-cleanup queries from realmd at login

now they just getting executed when realmd is started

i think this will improve speed a bit.. cause we don't need to cleanup those
bans so often we just can check the conditions inside the select
This commit is contained in:
balrok 2009-11-14 08:48:35 -05:00
parent 31a2996374
commit fbe9241a96
3 changed files with 14 additions and 10 deletions

View file

@ -209,6 +209,11 @@ extern int main(int argc, char **argv)
return 1;
}
// cleanup query
//set expired bans to inactive
loginDatabase.Execute("UPDATE account_banned SET active = 0 WHERE unbandate<=UNIX_TIMESTAMP() AND unbandate<>bandate");
loginDatabase.Execute("DELETE FROM ip_banned WHERE unbandate<=UNIX_TIMESTAMP() AND unbandate<>bandate");
h.Add(&authListenSocket);
///- Catch termination signals