table of contents
MM_LOG_FATAL(3) | mmlib library manual | MM_LOG_FATAL(3) |
NAME¶
mm_log_fatal, mm_log_error, mm_log_warn, mm_log_info, mm_log_debug - Add a formatted message to the log file
SYNOPSIS¶
#include <mmlog.h>
void mm_log_fatal(msg, ...);
void mm_log_error(msg, ...);
void mm_log_warn(msg, ...);
void mm_log_info(msg, ...);
void mm_log_debug(msg, ...);
Link with -lmmlib
DESCRIPTION¶
Those macros writes a log entry (using mm_log(3)) using the level specified by the macro name. If the preprocessor definition MM_LOG_MAXLEVEL is smaller than the corresponding level of the macro, this macros is simply not exanded in the code.
The module name in the location string is defined by MM_LOG_MODULE_NAME. If unset when including mmlog.h, this definition is initialized to the value of PACKAGE_NAME. If MM_LOG_VERBOSE_LOCATION is defined, the filename and line number are prepended to the location string.
RETURN VALUE¶
None.
THREAD SAFETY¶
mm_log() is thread-safe.
EXAMPLE¶
2012 |