From 8589c1a040a629a7cd98bc6d49737e14361380b3 Mon Sep 17 00:00:00 2001 From: Philipp Schafft Date: Wed, 9 Jan 2019 15:39:55 +0000 Subject: [PATCH] Feature: Actually disable developer only logging if --enable-devel-logging is not given --- src/logging.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/logging.h b/src/logging.h index b436c68e..0fb0fece 100644 --- a/src/logging.h +++ b/src/logging.h @@ -50,10 +50,17 @@ extern int playlistlog; #define ICECAST_LOG_INFO(...) ICECAST_LOG(ICECAST_LOGLEVEL_INFO, ICECAST_LOGFLAG_NONE, __VA_ARGS__) #define ICECAST_LOG_DEBUG(...) ICECAST_LOG(ICECAST_LOGLEVEL_DEBUG, ICECAST_LOGFLAG_NONE, __VA_ARGS__) /* Currently only an alias for ICECAST_LOG_DEBUG() */ +#ifdef DEVEL_LOGGING #define ICECAST_LOG_DERROR(...) ICECAST_LOG(ICECAST_LOGLEVEL_ERROR, ICECAST_LOGFLAG_DEVEL, __VA_ARGS__) #define ICECAST_LOG_DWARN(...) ICECAST_LOG(ICECAST_LOGLEVEL_WARN, ICECAST_LOGFLAG_DEVEL, __VA_ARGS__) #define ICECAST_LOG_DINFO(...) ICECAST_LOG(ICECAST_LOGLEVEL_INFO, ICECAST_LOGFLAG_DEVEL, __VA_ARGS__) #define ICECAST_LOG_DDEBUG(...) ICECAST_LOG(ICECAST_LOGLEVEL_DEBUG, ICECAST_LOGFLAG_DEVEL, __VA_ARGS__) +#else +#define ICECAST_LOG_DERROR(...) +#define ICECAST_LOG_DWARN(...) +#define ICECAST_LOG_DINFO(...) +#define ICECAST_LOG_DDEBUG(...) +#endif /* CATMODULE is the category or module that logging messages come from. ** we set one here in cause someone forgets in the .c file.