logging: disable all debug messages in non-debug build

For consistency, don't print debug messages that are compiled in due to
using the LOG macro instead of DEBUG_LOG.
This commit is contained in:
Miroslav Lichvar
2019-11-19 14:59:21 +01:00
parent 07badbede7
commit c7223f4c8f
2 changed files with 4 additions and 1 deletions

View File

@@ -214,7 +214,8 @@ LOG_OpenSystemLog(void)
void LOG_SetMinSeverity(LOG_Severity severity)
{
log_min_severity = CLAMP(LOGS_DEBUG, severity, LOGS_FATAL);
/* Don't print any debug messages in a non-debug build */
log_min_severity = CLAMP(DEBUG > 0 ? LOGS_DEBUG : LOGS_INFO, severity, LOGS_FATAL);
}
/* ================================================== */