Remove log level FATA.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
#define WEBCC_ENABLE_LOG 1
|
||||
|
||||
#if WEBCC_ENABLE_LOG
|
||||
// 0:VERB, 1:INFO, 2:WARN, 3:ERRO or 4:FATA
|
||||
// 0:VERB, 1:INFO, 2:WARN or 3:ERRO
|
||||
#define WEBCC_LOG_LEVEL 2
|
||||
#endif
|
||||
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@
|
||||
#define WEBCC_ENABLE_LOG @WEBCC_ENABLE_LOG@
|
||||
|
||||
#if WEBCC_ENABLE_LOG
|
||||
// 0:VERB, 1:INFO, 2:WARN, 3:ERRO or 4:FATA
|
||||
// 0:VERB, 1:INFO, 2:WARN or 3:ERRO
|
||||
#define WEBCC_LOG_LEVEL @WEBCC_LOG_LEVEL@
|
||||
#endif
|
||||
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
#define WEBCC_INFO 1
|
||||
#define WEBCC_WARN 2
|
||||
#define WEBCC_ERRO 3
|
||||
#define WEBCC_FATA 4
|
||||
|
||||
// Default log level.
|
||||
#ifndef WEBCC_LOG_LEVEL
|
||||
@@ -84,13 +83,6 @@ void Log(int level, const char* file, int line, const char* format, ...);
|
||||
#define LOG_ERRO(format, ...)
|
||||
#endif
|
||||
|
||||
#if WEBCC_LOG_LEVEL <= WEBCC_FATA
|
||||
#define LOG_FATA(format, ...) \
|
||||
webcc::Log(WEBCC_FATA, __FILENAME__, __LINE__, format, ##__VA_ARGS__);
|
||||
#else
|
||||
#define LOG_FATA(format, ...)
|
||||
#endif
|
||||
|
||||
#else
|
||||
|
||||
// See: https://stackoverflow.com/a/8488201
|
||||
@@ -124,13 +116,6 @@ void Log(int level, const char* file, int line, const char* format, ...);
|
||||
#define LOG_ERRO(format, args...)
|
||||
#endif
|
||||
|
||||
#if WEBCC_LOG_LEVEL <= WEBCC_FATA
|
||||
#define LOG_FATA(format, args...) \
|
||||
webcc::Log(WEBCC_FATA, __FILENAME__, __LINE__, format, ##args);
|
||||
#else
|
||||
#define LOG_FATA(format, args...)
|
||||
#endif
|
||||
|
||||
#endif // defined(WIN32) || defined(_WIN64)
|
||||
|
||||
#else // WEBCC_ENABLE_LOG == 0
|
||||
@@ -142,13 +127,11 @@ void Log(int level, const char* file, int line, const char* format, ...);
|
||||
#define LOG_INFO(format, ...)
|
||||
#define LOG_WARN(format, ...)
|
||||
#define LOG_ERRO(format, ...)
|
||||
#define LOG_FATA(format, ...)
|
||||
#else
|
||||
#define LOG_VERB(format, args...)
|
||||
#define LOG_INFO(format, args...)
|
||||
#define LOG_WARN(format, args...)
|
||||
#define LOG_ERRO(format, args...)
|
||||
#define LOG_FATA(format, args...)
|
||||
#endif // defined(WIN32) || defined(_WIN64)
|
||||
|
||||
#endif // WEBCC_ENABLE_LOG
|
||||
|
||||
Reference in New Issue
Block a user