Core/Misc: Fix static analysis issues

This commit is contained in:
jackpoz
2017-07-16 18:16:48 +02:00
parent f44956b051
commit 9cf4dd7345
13 changed files with 35 additions and 48 deletions

View File

@@ -587,8 +587,7 @@ public:
static bool HandleBanListIPCommand(ChatHandler* handler, char const* args)
{
PreparedStatement* stmt = nullptr;
stmt = LoginDatabase.GetPreparedStatement(LOGIN_DEL_EXPIRED_IP_BANS);
PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_DEL_EXPIRED_IP_BANS);
LoginDatabase.Execute(stmt);
char* filterStr = strtok((char*)args, " ");

View File

@@ -187,8 +187,7 @@ public:
break;
}
PreparedStatement* stmt = nullptr;
stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_DISABLES);
PreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_DISABLES);
stmt->setUInt32(0, entry);
stmt->setUInt8(1, disableType);
PreparedQueryResult result = WorldDatabase.Query(stmt);
@@ -313,8 +312,7 @@ public:
break;
}
PreparedStatement* stmt = nullptr;
stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_DISABLES);
PreparedStatement* stmt = WorldDatabase.GetPreparedStatement(WORLD_SEL_DISABLES);
stmt->setUInt32(0, entry);
stmt->setUInt8(1, disableType);
PreparedQueryResult result = WorldDatabase.Query(stmt);