DES-SERT - A Simple and Extensible Routing Framework for Testbeds: L O G _ F A C I L I T Y

# L O G _ F A C I L I T Y

EXTERNAL / PUBLIC. More...

## Defines
#define | DESSERT_LOG_SYSLOG 0x0001
| flag for dessert_logcfg - enable syslog logging
#define | DESSERT_LOG_NOSYSLOG 0x0002
| flag for dessert_logcfg - disable syslog logging
#define | DESSERT_LOG_FILE 0x0004
| flag for dessert_logcfg - enable logfile logging
#define | DESSERT_LOG_NOFILE 0x0008
| flag for dessert_logcfg - disable logfile logging
#define | DESSERT_LOG_STDERR 0x0010
| flag for dessert_logcfg - enable logging to stderr
#define | DESSERT_LOG_NOSTDERR 0x0020
| flag for dessert_logcfg - disable logging to stderr
#define | DESSERT_LOG_RBUF 0x0040
| flag for dessert_logcfg - enable logging to ringbuffer
#define | DESSERT_LOG_NORBUF 0x0080
| flag for dessert_logcfg - disable logging to ringbuffer
#define | DESSERT_LOG_DEBUG 0x0100
| flag for dessert_logcfg - enable debug loglevel
#define | DESSERT_LOG_NODEBUG 0x0200
| flag for dessert_logcfg - disable debug loglevel
#define | dessert_debug(...) _dessert_log(LOG_DEBUG, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at DEBUG level
#define | dessert_info(...) _dessert_log(LOG_INFO, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at INFO level
#define | dessert_notice(...) _dessert_log(LOG_NOTICE, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at NOTICE level
#define | dessert_warn(...) _dessert_log(LOG_WARNING, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at WARNING level
#define | dessert_warning(...) _dessert_log(LOG_WARNING, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at WARNING level
#define | dessert_err(...) _dessert_log(LOG_ERR, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at ERR level
#define | dessert_crit(...) _dessert_log(LOG_CRIT, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at CRIT level
#define | dessert_alert(...) _dessert_log(LOG_ALERT, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at ALERT level
#define | dessert_emerg(...) _dessert_log(LOG_EMERG, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
| log at EMERG level
## Functions
int | dessert_logcfg (uint16_t opts)
| Configure dessert logging framework and sets up logging.
void | _dessert_log (int level, const char *func, const char *file, int line, const char *fmt,...)
| internal log function

## Detailed Description

EXTERNAL / PUBLIC.

## Define Documentation

#define DESSERT_LOG_FILE 0x0004

flag for dessert_logcfg - enable logfile logging

Warning:
  before using this you MUST use fopen(dessert_logfd, ...) to open the logfile

## Function Documentation

int dessert_logcfg | ( | uint16_t | opts | ) |

Configure dessert logging framework and sets up logging.

- opts OR'd flags -
  See also:
    DESSERT_LOG_*
  DESCRIPTION: