aboutsummaryrefslogtreecommitdiff
path: root/src/server/shared/Database/PreparedStatement.cpp
diff options
context:
space:
mode:
authorSpp <spp@jorge.gr>2013-01-02 14:20:20 +0100
committerSpp <spp@jorge.gr>2013-01-02 14:20:20 +0100
commit601fcc5612a3788b3f22f98c89809235d0b725a7 (patch)
treebcd069b5c670e209c1372595acd14c7e376cee7a /src/server/shared/Database/PreparedStatement.cpp
parentebd14b4f01cc64a2a488bdbb1046897cc4da8e9a (diff)
Core/Misc: Removed odd code from CreatureAIImpl.h, it does not belong here
- Also some minor corrections from previous commit
Diffstat (limited to 'src/server/shared/Database/PreparedStatement.cpp')
-rw-r--r--src/server/shared/Database/PreparedStatement.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/shared/Database/PreparedStatement.cpp b/src/server/shared/Database/PreparedStatement.cpp
index 3256c3c9db3..86010e61686 100644
--- a/src/server/shared/Database/PreparedStatement.cpp
+++ b/src/server/shared/Database/PreparedStatement.cpp
@@ -33,7 +33,7 @@ void PreparedStatement::BindParameters()
{
ASSERT (m_stmt);
- uint32 i = 0;
+ uint8 i = 0;
for (; i < statement_data.size(); i++)
{
switch (statement_data[i].type)
@@ -241,7 +241,7 @@ void MySQLPreparedStatement::ClearParameters()
}
}
-static bool ParementerIndexAssertFail(uint32 stmtIndex, uint8 index, uint32 paramCount)
+static bool ParamenterIndexAssertFail(uint32 stmtIndex, uint8 index, uint32 paramCount)
{
sLog->outError(LOG_FILTER_SQL_DRIVER, "Attempted to bind parameter %u%s on a PreparedStatement %u (statement has only %u parameters)", uint32(index) + 1, (index == 1 ? "st" : (index == 2 ? "nd" : (index == 3 ? "rd" : "nd"))), stmtIndex, paramCount);
return false;
@@ -250,7 +250,7 @@ static bool ParementerIndexAssertFail(uint32 stmtIndex, uint8 index, uint32 para
//- Bind on mysql level
bool MySQLPreparedStatement::CheckValidIndex(uint8 index)
{
- ASSERT(index < m_paramCount || ParementerIndexAssertFail(m_stmt->m_index, index, m_paramCount));
+ ASSERT(index < m_paramCount || ParamenterIndexAssertFail(m_stmt->m_index, index, m_paramCount));
if (m_paramsSet[index])
sLog->outWarn(LOG_FILTER_SQL, "[WARNING] Prepared Statement (id: %u) trying to bind value on already bound index (%u).", m_stmt->m_index, index);
@@ -386,7 +386,7 @@ void MySQLPreparedStatement::setValue(MYSQL_BIND* param, enum_field_types type,
memcpy(param->buffer, value, len);
}
-std::string MySQLPreparedStatement::getQueryString(std::string const &sqlPattern) const
+std::string MySQLPreparedStatement::getQueryString(std::string const& sqlPattern) const
{
std::string queryString = sqlPattern;