aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorlinencloth <none@none>2010-12-23 08:03:57 +0100
committerlinencloth <none@none>2010-12-23 08:03:57 +0100
commitb89994fc3f4566e50ccbf40294c4ba3ecc4c50f7 (patch)
tree6734b6667a24c4ccc38ff440521c08875eb37325 /src
parent2ee9a528ca3a18fd8869695d72ea3c54fbca8aa6 (diff)
Core/AuthServer: Little more query tuning. Missed by leak.
--HG-- branch : trunk
Diffstat (limited to 'src')
-rwxr-xr-xsrc/server/shared/Database/Implementation/LoginDatabase.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/shared/Database/Implementation/LoginDatabase.cpp b/src/server/shared/Database/Implementation/LoginDatabase.cpp
index 9487dec3ae5..3b687d03d44 100755
--- a/src/server/shared/Database/Implementation/LoginDatabase.cpp
+++ b/src/server/shared/Database/Implementation/LoginDatabase.cpp
@@ -31,8 +31,8 @@ bool LoginDatabaseConnection::Open()
##################################
*/
PrepareStatement(LOGIN_GET_REALMLIST, "SELECT id, name, address, port, icon, color, timezone, allowedSecurityLevel, population, gamebuild FROM realmlist WHERE color <> 3 ORDER BY name");
- PrepareStatement(LOGIN_SET_EXPIREDIPBANS, "DELETE FROM ip_banned WHERE unbandate<=UNIX_TIMESTAMP() AND unbandate<>bandate", true);
- PrepareStatement(LOGIN_SET_EXPIREDACCBANS, "UPDATE account_banned SET active = 0 WHERE active = 1 AND unbandate<=UNIX_TIMESTAMP() AND unbandate<>bandate", true);
+ PrepareStatement(LOGIN_SET_EXPIREDIPBANS, "DELETE FROM ip_banned WHERE unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()", true);
+ PrepareStatement(LOGIN_SET_EXPIREDACCBANS, "UPDATE account_banned SET active = 0 WHERE active = 1 AND unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()", true);
PrepareStatement(LOGIN_GET_IPBANNED, "SELECT * FROM ip_banned WHERE ip = ?");
PrepareStatement(LOGIN_SET_IPAUTOBANNED, "INSERT INTO ip_banned VALUES (?, UNIX_TIMESTAMP(), UNIX_TIMESTAMP()+?,'Trinity realmd', 'Failed login autoban')", true);
PrepareStatement(LOGIN_GET_ACCBANNED, "SELECT bandate,unbandate FROM account_banned WHERE id = ? AND active = 1");