For consistency, don't print debug messages that are compiled in due to
using the LOG macro instead of DEBUG_LOG.
csv_mode = 1;
break;
case 'd':
+#if DEBUG > 0
log_min_severity = LOGS_DEBUG;
+#endif
break;
case 'h':
hostnames = optarg;
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);
}
/* ================================================== */