mirror of
https://git.h3cjp.net/H3cJP/yuzu.git
synced 2024-11-11 20:03:14 +00:00
log: updated MAX_LOGLEVEL to use correct log level enum type
This commit is contained in:
parent
5cd922d151
commit
00adbc7817
|
@ -94,10 +94,10 @@ void GenericLog(LOGTYPES_LEVELS level, LOGTYPES_TYPE type, const char*file, int
|
||||||
;
|
;
|
||||||
|
|
||||||
#if defined LOGGING || defined _DEBUG || defined DEBUGFAST
|
#if defined LOGGING || defined _DEBUG || defined DEBUGFAST
|
||||||
#define MAX_LOGLEVEL DEBUG_LEVEL
|
#define MAX_LOGLEVEL LDEBUG
|
||||||
#else
|
#else
|
||||||
#ifndef MAX_LOGLEVEL
|
#ifndef MAX_LOGLEVEL
|
||||||
#define MAX_LOGLEVEL WARNING_LEVEL
|
#define MAX_LOGLEVEL LWARNING
|
||||||
#endif // loglevel
|
#endif // loglevel
|
||||||
#endif // logging
|
#endif // logging
|
||||||
|
|
||||||
|
@ -109,7 +109,7 @@ void GenericLog(LOGTYPES_LEVELS level, LOGTYPES_TYPE type, const char*file, int
|
||||||
|
|
||||||
// Let the compiler optimize this out
|
// Let the compiler optimize this out
|
||||||
#define GENERIC_LOG(t, v, ...) { \
|
#define GENERIC_LOG(t, v, ...) { \
|
||||||
if (v <= MAX_LOGLEVEL) \
|
if (v <= LogTypes::MAX_LOGLEVEL) \
|
||||||
GenericLog(v, t, __FILE__, __LINE__, __func__, __VA_ARGS__); \
|
GenericLog(v, t, __FILE__, __LINE__, __func__, __VA_ARGS__); \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -149,7 +149,7 @@ LogContainer::LogContainer(const char* shortName, const char* fullName, bool ena
|
||||||
{
|
{
|
||||||
strncpy(m_fullName, fullName, 128);
|
strncpy(m_fullName, fullName, 128);
|
||||||
strncpy(m_shortName, shortName, 32);
|
strncpy(m_shortName, shortName, 32);
|
||||||
m_level = (LogTypes::LOG_LEVELS)MAX_LOGLEVEL;
|
m_level = LogTypes::MAX_LOGLEVEL;
|
||||||
}
|
}
|
||||||
|
|
||||||
// LogContainer
|
// LogContainer
|
||||||
|
|
|
@ -97,7 +97,7 @@ private:
|
||||||
~LogManager();
|
~LogManager();
|
||||||
public:
|
public:
|
||||||
|
|
||||||
static u32 GetMaxLevel() { return MAX_LOGLEVEL; }
|
static u32 GetMaxLevel() { return LogTypes::MAX_LOGLEVEL; }
|
||||||
|
|
||||||
void Log(LogTypes::LOG_LEVELS level, LogTypes::LOG_TYPE type, const char* file, int line,
|
void Log(LogTypes::LOG_LEVELS level, LogTypes::LOG_TYPE type, const char* file, int line,
|
||||||
const char* function, const char *fmt, va_list args);
|
const char* function, const char *fmt, va_list args);
|
||||||
|
|
Loading…
Reference in a new issue