diff --git a/src/logger.cpp b/src/logger.cpp index 7416f8259342e2c0e35666c4c4254f81f373eaa8..113b0ca626db9aa57afe1cc5bb5e37546e35b105 100644 --- a/src/logger.cpp +++ b/src/logger.cpp @@ -210,9 +210,10 @@ namespace jami { void Logger::log(int level, const char* file, int line, bool linefeed, const char* const format, ...) { -#if defined(TARGET_OS_IOS) && TARGET_OS_IOS && !debugMode - return; -#else +#if defined(TARGET_OS_IOS) && TARGET_OS_IOS + if(!debugMode) + return; +#endif if (!debugMode && level == LOG_DEBUG) return; @@ -224,16 +225,16 @@ Logger::log(int level, const char* file, int line, bool linefeed, const char* co Logger::vlog(level, file, line, linefeed, format, ap); #endif va_end(ap); -#endif } void Logger::vlog(const int level, const char* file, int line, bool linefeed, const char* format, va_list ap) { -#if defined(TARGET_OS_IOS) && TARGET_OS_IOS && !debugMode - return; -#else +#if defined(TARGET_OS_IOS) && TARGET_OS_IOS + if(!debugMode) + return; +#endif if (!debugMode && level == LOG_DEBUG) return; @@ -298,7 +299,6 @@ Logger::vlog(const int level, const char* file, int line, bool linefeed, } else { ::vsyslog(level, format, ap); } -#endif } } // namespace jami;