8e8dae83461e756a267c411c1fd9485000b31d59
3 * @author David Llewellyn-Jones <david@flypig.co.uk>
8 * Copyright David Llewellyn-Jones, 2020
9 * Released under the GPLv2.
11 * @brief Allows output to be sent to the log
12 * @section DESCRIPTION
14 * This is a simple set of functions and macros that allows strings to be
15 * recorded in the syslog.
19 /** \addtogroup Logging
33 * Log a string to syslog.
35 * Constructs a message using the supplied format and parameters and records it
36 * in the system log. The format is the same as for printf.
38 * The logging levels are the standard syslog levels:
40 * LOG_DEBUG, LOG_INFO, LOG_WARNING, LOG_ERR, etc.
42 * @param priority The log level priority.
43 * @param format The format for the message, the same as for printf.
44 * @param ... parameters to combine with the format to create the message.
46 #define LOG(level, ...) log_priority(level, __VA_ARGS__);
50 // Function prototypes
52 void log_priority(int priority
, const char *format
, ...);
54 // Function definitions
58 /** @} addtogroup Logging*/