diff options
author | click <none@none> | 2010-08-22 01:57:04 +0200 |
---|---|---|
committer | click <none@none> | 2010-08-22 01:57:04 +0200 |
commit | 670964803f030c6d2b85d4281605ab221f5a5740 (patch) | |
tree | 5babaf3c1c2f7833bf2be8b10a1f7bec78722751 /src/server/shared/Logging/Log.cpp | |
parent | a40cb46e610aefde8b270b34e9b510e76470a6b6 (diff) |
Core: Fix more warnings, add new function sLog.outStaticDebug() that replaces DEBUG_LOG
--HG--
branch : trunk
Diffstat (limited to 'src/server/shared/Logging/Log.cpp')
-rw-r--r-- | src/server/shared/Logging/Log.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/server/shared/Logging/Log.cpp b/src/server/shared/Logging/Log.cpp index 3856769cbae..500701d0491 100644 --- a/src/server/shared/Logging/Log.cpp +++ b/src/server/shared/Logging/Log.cpp @@ -734,6 +734,18 @@ void Log::outDebug(const char * str, ...) fflush(stdout); } +void Log::outStaticDebug(const char * fmt, ...) +{ + #ifdef TRINITY_DEBUG + va_list ap; + char str[2048]; + va_start(ap, str); + vsnprintf(str, 2048, fmt, ap); + va_end(ap); + outDebug(str); + #endif +} + void Log::outStringInLine(const char * str, ...) { if (!str) |