diff options
author | Spp <spp@jorge.gr> | 2013-05-13 15:07:36 +0200 |
---|---|---|
committer | Spp <spp@jorge.gr> | 2013-05-13 15:07:36 +0200 |
commit | d1677b2db08f71a5bddedd9659cc5a66f325f47f (patch) | |
tree | afb68e15d84d4e64de9f80b9bbbeb126c4aa8c54 /src/server/shared/Database/QueryHolder.cpp | |
parent | 243c325ca4323feb4f7f80c0ecd3873c78cbf887 (diff) |
Core/Logging: Performance-related tweaks to logging system
All sLog->out* functions (except outCommand atm) are replaced with TC_LOG_* macros.
Memleak fix
Diffstat (limited to 'src/server/shared/Database/QueryHolder.cpp')
-rw-r--r-- | src/server/shared/Database/QueryHolder.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/shared/Database/QueryHolder.cpp b/src/server/shared/Database/QueryHolder.cpp index 38496860955..0a7c19af6d0 100644 --- a/src/server/shared/Database/QueryHolder.cpp +++ b/src/server/shared/Database/QueryHolder.cpp @@ -24,7 +24,7 @@ bool SQLQueryHolder::SetQuery(size_t index, const char *sql) { if (m_queries.size() <= index) { - sLog->outError(LOG_FILTER_SQL, "Query index (%u) out of range (size: %u) for query: %s", uint32(index), (uint32)m_queries.size(), sql); + TC_LOG_ERROR(LOG_FILTER_SQL, "Query index (%u) out of range (size: %u) for query: %s", uint32(index), (uint32)m_queries.size(), sql); return false; } @@ -44,7 +44,7 @@ bool SQLQueryHolder::SetPQuery(size_t index, const char *format, ...) { if (!format) { - sLog->outError(LOG_FILTER_SQL, "Query (index: %u) is empty.", uint32(index)); + TC_LOG_ERROR(LOG_FILTER_SQL, "Query (index: %u) is empty.", uint32(index)); return false; } @@ -56,7 +56,7 @@ bool SQLQueryHolder::SetPQuery(size_t index, const char *format, ...) if (res == -1) { - sLog->outError(LOG_FILTER_SQL, "SQL Query truncated (and not execute) for format: %s", format); + TC_LOG_ERROR(LOG_FILTER_SQL, "SQL Query truncated (and not execute) for format: %s", format); return false; } @@ -67,7 +67,7 @@ bool SQLQueryHolder::SetPreparedQuery(size_t index, PreparedStatement* stmt) { if (m_queries.size() <= index) { - sLog->outError(LOG_FILTER_SQL, "Query index (%u) out of range (size: %u) for prepared statement", uint32(index), (uint32)m_queries.size()); + TC_LOG_ERROR(LOG_FILTER_SQL, "Query index (%u) out of range (size: %u) for prepared statement", uint32(index), (uint32)m_queries.size()); return false; } |