![]() |
librnr
1.14.5
RoadNarrows Robotics Common Library 1
|
Logger declarations. More...
#include <stdio.h>#include <stdarg.h>#include <errno.h>#include <string.h>#include <ctype.h>#include "rnr/rnrconfig.h"Go to the source code of this file.
Macros | |
| #define | CONCAT_(x, y) x ## y |
| build concatenation operator | |
| #define | CONCAT(x, y) CONCAT_(x, y) |
| now concatenate | |
| #define | MKSTR_(x) #x |
| build token into string operator | |
| #define | MKSTR(x) MKSTR_(x) |
| now make string literal | |
| #define | LOGNS |
| < default logging namespace More... | |
| #define | LOGNS_NAME "" |
| default logging preface string More... | |
| #define | LOGNS_PUT(id) CONCAT(LOGNS, id) |
| put identifier into namespace | |
| #define | LOGMOD |
| default logging module name | |
| #define | LOG_PREFACE_TEXT "" |
| no logging preface | |
| #define | LOG_VAR_THRESHOLD LOGNS_PUT(LogThresholdLevel) |
| current threshold variable name | |
| #define | LOG_SET_THRESHOLD LOGNS_PUT(LogSetThresholdLevel) |
| set threshold function name | |
| #define | LOG_GET_THRESHOLD LOGNS_PUT(LogGetThresholdLevel) |
| get threshold function name | |
| #define | LOG_VAR_COLOR_EN LOGNS_PUT(LogColorEnable) |
| logging in color is [not] enabled | |
| #define | LOG_SET_LOGFILE LogSetLogFile |
| set output log file function name | |
| #define | LOG_GET_LOGFILE LogGetLogFile |
| get output log file function name | |
| #define | LOG_SET_COLOR_ENABLE LogSetColorEnable |
| enable/disable logging in color func name | |
| #define | LOG_SET_TIMESTAMP_ENABLE LogSetTimestampEnable |
| enable/disable logging timestamps func name | |
| #define | LOG_ATTACH_LOGFP LogAttachLogFp |
| attach file pointer as logging out stream | |
| #define | LOG_GET_LOGFP LogGetLogFp |
| get current logging out stream file pointer | |
| #define | LOGGER LogPrintf |
| logger function name | |
| #define | LOGGER_CALL LogCallPrintf |
| logger of "function call" function name | |
| #define | LOGGING_NA -1 |
| logging not available (not compiled) | |
| #define | LOG_LEVEL_OFF 0 |
| turn off all non-error logging | |
| #define | LOG_LEVEL_ERROR 1 |
| errors | |
| #define | LOG_LEVEL_DIAG1 2 |
| diagnostic level 1 | |
| #define | LOG_LEVEL_DIAG2 3 |
| diagnostic level 2 | |
| #define | LOG_LEVEL_DIAG3 4 |
| diagnostic level 3 | |
| #define | LOG_LEVEL_DIAG4 5 |
| diagnostic level 4 | |
| #define | LOG_LEVEL_DIAG5 6 |
| diagnostic level 5 | |
| #define | LOG_LEVEL_DFT 0 |
| default log level is off | |
| #define | LOGABLE(level) ((level) <= LOG_VAR_THRESHOLD) |
| Test if given level is logable at current threshold. More... | |
| #define | LOG_IN_COLOR() (LOG_VAR_COLOR_EN) |
| Test if logging in color. | |
| #define | LOG_WITH_TIMESTAMP() (LOG_VAR_TIMESTAMP_EN) |
| Test if logging includes timestamps. | |
| #define | LOG_FILENAME_STDERR "stderr" |
| 'stderr' log filename | |
| #define | LOG_FILENAME_STDOUT "stdout" |
| 'stdout' log filename | |
| #define | LOG_FILENAME_DFT LOG_FILENAME_STDERR |
| default log filename | |
| #define | LOG_FP_DFT stderr |
| default log out stream | |
| #define | LOG_COLOR_EN_DFT true |
| default is to log in color | |
| #define | LOG_TIMESTAMP_EN_DFT true |
| default is to include timestamps | |
| #define | LOGFUNCNAME __func__ |
| function name | |
| #define | LOG_COLOR_PRE "\033[" |
| color escape sequence prefix | |
| #define | LOG_COLOR_POST "\033[0m" |
| color escape sequence postfix | |
| #define | LOG_COLOR_RED "0;31m" |
| normal red | |
| #define | LOG_COLOR_GREEN "0;32m" |
| normal green | |
| #define | LOG_COLOR_YELLOW "0;33m" |
| normal yellow | |
| #define | LOG_COLOR_BLUE "0;34m" |
| normal blue | |
| #define | LOG_COLOR_MAGENTA "0;35m" |
| normal magenta | |
| #define | LOG_COLOR_CYAN "0;36m" |
| normal cyan | |
| #define | LOG_COLOR_LIGHT_RED "1;31m" |
| light red | |
| #define | LOG_COLOR_LIGHT_GREEN "1;32m" |
| light green | |
| #define | LOG_COLOR_LIGHT_YELLOW "1;33m" |
| light yellow | |
| #define | LOG_COLOR_LIGHT_BLUE "1;34m" |
| light blue | |
| #define | LOG_COLOR_LIGHT_MAGENTA "1;35m" |
| light magenta | |
| #define | LOG_COLOR_LIGHT_CYAN "1;36m" |
| light cyan | |
| #define | LOG_COLOR_ERROR LOG_COLOR_PRE LOG_COLOR_RED |
| error color | |
| #define | LOG_COLOR_WARN LOG_COLOR_PRE LOG_COLOR_YELLOW |
| warning color | |
| #define | LOG_COLOR_DIAG LOG_COLOR_PRE LOG_COLOR_GREEN |
| diagnostics color | |
| #define | LOG_PREFACE LOG_PREFACE_TEXT |
| loging preface string | |
| #define | LOG_PREFACE_PLAIN LOG_PREFACE_TEXT |
| loging preface with no color | |
| #define | LOGARGS_DIAG(level, fmt, ...) |
| Standard diagnostic logging output arguments with compiled color. More... | |
| #define | LOGARGS_DIAG_PLAIN(level, fmt, ...) |
| Standard diagnostic logging output arguments in plain text. More... | |
| #define | LOGARGS_WARN(fmt, ...) |
| Standard warning logging output arguments with compiled color. More... | |
| #define | LOGARGS_WARN_PLAIN(fmt, ...) LOG_PREFACE_PLAIN "Warning: %s[%d] " fmt, __FILE__, __LINE__, ##__VA_ARGS__ |
| Standard warning logging output arguments in plain text. More... | |
| #define | LOGARGS_ERR(fmt, ...) |
| Standard error logging output arguments with compiled color. More... | |
| #define | LOGARGS_ERR_PLAIN(fmt, ...) LOG_PREFACE_PLAIN "Error: %s[%d] " fmt, __FILE__, __LINE__, ##__VA_ARGS__ |
| Standard error logging output arguments in plain text. More... | |
| #define | LOGARGS_SYSERR(fmt, ...) |
| Standard system error logging output arguments with compiled color. More... | |
| #define | LOGARGS_SYSERR_PLAIN(fmt, ...) |
| Standard system error logging output arguments with compiled color. More... | |
| #define | LOGDIAG(level, fmt, ...) |
| Standard Diagnostic logging. More... | |
| #define | LOGUSER(level, fmt, ...) LOGDIAG(level+LOG_LEVEL_DIAG3+1, fmt, ##__VA_ARGS__) |
| Standard User Diagnostic logging. More... | |
| #define | LOGDIAG5(fmt, ...) LOGDIAG(LOG_LEVEL_DIAG5, fmt, ##__VA_ARGS__) |
| Standard Diagnostic Level 5 logging. More... | |
| #define | LOGDIAG4(fmt, ...) LOGDIAG(LOG_LEVEL_DIAG4, fmt, ##__VA_ARGS__) |
| Standard Diagnostic Level 4 logging. More... | |
| #define | LOGDIAG3(fmt, ...) LOGDIAG(LOG_LEVEL_DIAG3, fmt, ##__VA_ARGS__) |
| Standard Diagnostic Level 3 logging. More... | |
| #define | LOGDIAG2(fmt, ...) LOGDIAG(LOG_LEVEL_DIAG2, fmt, ##__VA_ARGS__) |
| Standard Diagnostic Level 2 logging. More... | |
| #define | LOGDIAG1(fmt, ...) LOGDIAG(LOG_LEVEL_DIAG1, fmt, ##__VA_ARGS__) |
| Standard Diagnostic Level 1 logging. More... | |
| #define | LOGDIAGCALL(level, ...) |
| Standard Diagnostic function call tracing. More... | |
| #define | LOGDIAG5CALL(...) LOGDIAGCALL(LOG_LEVEL_DIAG5, ##__VA_ARGS__) |
| Standard Diagnostic Level 5 function call tracing. More... | |
| #define | LOGDIAG4CALL(...) LOGDIAGCALL(LOG_LEVEL_DIAG4, ##__VA_ARGS__) |
| Standard Diagnostic Level 4 function call tracing. More... | |
| #define | LOGDIAG3CALL(...) LOGDIAGCALL(LOG_LEVEL_DIAG3, ##__VA_ARGS__) |
| Standard Diagnostic Level 3 function call tracing. More... | |
| #define | LOGDIAG2CALL(...) LOGDIAGCALL(LOG_LEVEL_DIAG2, ##__VA_ARGS__) |
| Standard Diagnostic Level 2 function call tracing. More... | |
| #define | LOGDIAG1CALL(...) LOGDIAGCALL(LOG_LEVEL_DIAG1, ##__VA_ARGS__) |
| Standard Diagnostic Level 1 function call tracing. More... | |
| #define | LOGWARN(fmt, ...) |
| Standard Warning logging. More... | |
| #define | LOGERROR(fmt, ...) |
| Standard Error logging. More... | |
| #define | LOGSYSERROR(fmt, ...) |
| Standard System Error logging. More... | |
| #define | _VARFMT(var, fmt) #var "=" fmt |
| log Variable Format. | |
| #define | _TF(b) ((b)? "true": "false") |
| boolean to string format | |
| #define | _CHARFMT(var) (isprint(var)? #var "='%c'": #var "=0x%02x") |
| char format string | |
| #define | _TFMT(var, fmt) #var "=" fmt, var |
| Family of 2-tuple ("<varname>=<fmt>", <var>) variable logging formatters. More... | |
| #define | _TSTR(var) _TFMT(var, "\"%s\"") |
| string variable | |
| #define | _TLONG(var) _TFMT(var, "%ld") |
| long int (decimal) | |
| #define | _TULONG(var) _TFMT(var, "%lu") |
| unsigned long int (decimal) | |
| #define | _THEX(var) _TFMT(var, "0x%x") |
| int (hex) | |
| #define | _TINT(var) _TFMT(var, "%d") |
| int (decimal) | |
| #define | _TUINT(var) _TFMT(var, "%u") |
| unsigned int (decimal) | |
| #define | _TSHORT(var) _TFMT(var, "%hd") |
| short int (decimal) | |
| #define | _TUSHORT(var) _TFMT(var, "%hu") |
| unsigned short (decimal) | |
| #define | _TFLOAT(var) _TFMT(var, "%f") |
| float | |
| #define | _TPTR(var) _TFMT(var, "%p") |
| pointer | |
| #define | _TBOOL(var) _VARFMT(var, "%s"), _TF(var) |
| boolean | |
| #define | _TCHAR(var) _CHARFMT(var), var |
| character | |
| #define | _TVEC(var, i, fmt) #var "[%d]=" fmt, i, var[i] |
| vector variable | |
| #define | _TVEC_UINT(var, i) _TVEC(var, i, "%u") |
| unsigned vector variable | |
| #define | LFF "%s()", LOGFUNCNAME |
| #define | LFF_ARGS(fmt, ...) "%s(" fmt "%s", LOGFUNCNAME, ##__VA_ARGS__, ")" |
| Log formatter for function with arguments. More... | |
| #define | LFF_BADARG(var, fmt, postfmt, ...) "%s(" #var "=" fmt "): " postfmt, LOGFUNCNAME, var, ##__VA_ARGS__ |
| Log formatter for function with a bad argument. More... | |
| #define | LFF_BADARG_VEC(var, i, fmt, postfmt, ...) "%s(" #var "[%d]=" fmt "): " postfmt, LOGFUNCNAME, i, var[i], ##__VA_ARGS__ |
| Log formatter for function with a bad vector argument. More... | |
| #define | CHKPTR(p, ...) |
| Checks validity of pointer. More... | |
| #define | CHKEXPR(val, expr, valfmt, ...) |
| Checks validity of value against the given validation expression. More... | |
| #define | CHKEXPR_INT(val, expr, ...) CHKEXPR(val, expr, "%d", ##__VA_ARGS__) |
| check integer | |
| #define | CHKEXPR_STR(val, expr, ...) CHKEXPR(val, expr, "'%s'", ##__VA_ARGS__) |
| check string | |
| #define | CHKEXPR_LONG(val, expr, ...) CHKEXPR(val, expr, "%ld", ##__VA_ARGS__) |
| check long integer | |
| #define | CHKEXPR_ULONG(val, expr, ...) CHKEXPR(val, expr, "%lu", ##__VA_ARGS__) |
| check unsigned long integer | |
| #define | CHKEXPR_HEX(val, expr, ...) CHKEXPR(val, expr, "0x%x", ##__VA_ARGS__) |
| check integer hex | |
| #define | CHKEXPR_UINT(val, expr, ...) CHKEXPR(val, expr, "%u", ##__VA_ARGS__) |
| check unsigned integer | |
| #define | CHKEXPR_SHORT(val, expr, ...) CHKEXPR(val, expr, "%hd",## __VA_ARGS__) |
| check short integer | |
| #define | CHKEXPR_USHORT(val, expr, ...) CHKEXPR(val, expr, "%hu", ##__VA_ARGS__) |
| check unsigned short integer | |
| #define | CHKEXPR_PTR(val, expr, ...) CHKEXPR(val, expr, "%p", ##__VA_ARGS__) |
| check pointer | |
| #define | LOGNS_DEF_BLOCK |
| If logging is defined is a different logging name space, then LOGNS_DEF must be included into the application or library. | |
Functions | |
| int | LogSetThresholdLevel (int nLevel) |
| int | LogGetThresholdLevel () |
| void | LogSetColorEnable (bool_t enable) |
| void | LogSetTimestampEnable (bool_t enable) |
| int | LogSetLogFile (const char *sLogFileName) |
| const char * | LogGetLogFile () |
| void | LogAttachLogFp (FILE *fp, const char *sFpFileName) |
| FILE * | LogGetLogFp () |
| void | LogPrintf (const char *sFmt,...) |
| void | LogCallPrintf (const char *sPreface, int nLevel, const char *sFile, int nLine, const char *sFuncName,...) |
Variables | |
| int | LogThresholdLevel |
| current logging threshold variable | |
| bool_t | LogColorEnable |
| color logging is [not] enabled | |
Logger declarations.
Logging supports error and diagnostics (debugging) reports to stderr or a specified file. Logging reporting is filtered by a simple threshold level.
The logging facilities are designed to support independent logging capabilities through namespaceing. Copy log.h and log.c to user application source tree and compile with LOGNS uniquely defined.
| Define | Threshold | Description |
|---|---|---|
| LOGGING_NA | -1 | Logging is not compiled into the application. See LOG_GET_THRESHOLD() to test level including this level. |
| LOG_LEVEL_OFF | 0 | Logging is turned off. |
| LOG_LEVEL_ERROR | 1 | Log only warnings and errors. |
| LOG_LEVEL_DIAG1 | 2 | Log errors plus level 1 diagnostics. |
| LOG_LEVEL_DIAG2 | 3 | Log errors plus level 1-2 diagnostics. |
| LOG_LEVEL_DIAG3 | 4 | Log errors plus level 1-3 diagnostics. |
| LOG_LEVEL_DIAG4 | 5 | Log errors plus level 1-4 diagnostics. |
| LOG_LEVEL_DIAG5 | 6 | Log errors plus level 1-5 diagnostics. |
| User Defined | ≥ 7 | User defined loggging levels. |
| Macro | Threshold | Description |
|---|---|---|
| LOGWARN() | 1 | Log warning message. |
| LOGERROR() | 1 | Log error message. |
| LOGSYSERROR() | 1 | Log system error message. The errno and associaed string will also be logged. |
| LOGDIAG1() | 2 | Log level 1 diagnostic message. |
| ~ | ~ | ~ |
| LOGDIAG5() | 6 | Log level 5 diagnostic message. |
| LOG_GET_THRESHOLD() | - | Get current logging level. |
| LOG_SET_THRESHOLD() | - | Set current logging level. |
| LOGFUNCNAME | - | Calling function or method name. |
—
Definition in file log.h.
| #define _TFMT | ( | var, | |
| fmt | |||
| ) | #var "=" fmt, var |
Family of 2-tuple ("<varname>=<fmt>", <var>) variable logging formatters.
The _T*() macros are used to create a format string, variable pair of the form: "<varname>=<fmt>",<var>
| var | Variable identifier. |
| fmt | Format string to print variable. |
| #define CHKEXPR | ( | val, | |
| expr, | |||
| valfmt, | |||
| ... | |||
| ) |
Checks validity of value against the given validation expression.
The CHKEXPR*() macros are used validate a value against an expression. If the expression evaluates to false, then log an error message and return from the embedding functin with the given (optional) error return code.
| val | Value identifier to check. |
| expr | Validation expression to evaluate. |
| valfmt | Value format string to use on error. |
| ... | Error return code (optional). |
| #define CHKPTR | ( | p, | |
| ... | |||
| ) |
Checks validity of pointer.
If null then log error and return from the embedding function with given (optional) error return code.
| p | Pointer that should not be NULL. |
| ... | Error return code (optional). |
Definition at line 651 of file log.h.
Referenced by AssocMapVoidXtoY(), AssocMapVoidYtoX(), ConfigDbGetName(), ConfigDbRead(), ConfigDbReadFp(), ConfigDbSetName(), ConfigSectionNew(), DListVoidAppend(), DListVoidDeleteNode(), DListVoidDeleteNodeAt(), DListVoidFindNode(), DListVoidGetNodeAt(), DListVoidInsert(), DListVoidIterNodeFirst(), DListVoidIterNodeLast(), DListVoidIterNodeNext(), DListVoidIterNodePrev(), DListVoidPrepend(), DListVoidUnlinkDataAt(), DListVoidUnlinkNodeAt(), SocketAttrGetClientData(), SocketAttrGetFlavor(), SocketAttrGetLocalName(), SocketAttrGetPort(), SocketAttrGetRemoteName(), SocketAttrGetSd(), SocketAttrHasFlavor(), SocketAttrSetClientData(), SocketAttrSetFlavor(), SocketAttrSetLocalName(), SocketAttrSetNonBlocking(), SocketAttrSetPort(), SocketAttrSetRemoteName(), SocketAttrSetSd(), SocketBufClear(), SocketBufGetBuf(), SocketBufGetLen(), SocketBufGetRawBuf(), SocketBufGetSize(), SocketBufNewBuf(), SocketBufSetBuf(), SocketClose(), SocketRead(), SocketWrite(), SockSetActivate(), SockSetAdd(), SockSetChkSd(), SockSetIterFirst(), SockSetIterNext(), SockSetPutOnHold(), SockSetRemove(), and SockSetSelect().
| #define LFF_ARGS | ( | fmt, | |
| ... | |||
| ) | "%s(" fmt "%s", LOGFUNCNAME, ##__VA_ARGS__, ")" |
| #define LFF_BADARG | ( | var, | |
| fmt, | |||
| postfmt, | |||
| ... | |||
| ) | "%s(" #var "=" fmt "): " postfmt, LOGFUNCNAME, var, ##__VA_ARGS__ |
| #define LFF_BADARG_VEC | ( | var, | |
| i, | |||
| fmt, | |||
| postfmt, | |||
| ... | |||
| ) | "%s(" #var "[%d]=" fmt "): " postfmt, LOGFUNCNAME, i, var[i], ##__VA_ARGS__ |
Log formatter for function with a bad vector argument.
Format: function(var[i]=val): errmsg
| var | Vector variable identifier. |
| i | Variable index. |
| fmt | Format string to print function argument. |
| postfmt | Format string to print after function string. |
| ... | Arguments to postfmt string |
| #define LOGABLE | ( | level | ) | ((level) <= LOG_VAR_THRESHOLD) |
Test if given level is logable at current threshold.
| level | Level to test. |
Definition at line 195 of file log.h.
Referenced by init(), and NewSearchPathDList().
| #define LOGARGS_DIAG | ( | level, | |
| fmt, | |||
| ... | |||
| ) |
Standard diagnostic logging output arguments with compiled color.
| level | Loggging level. |
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 269 of file log.h.
Referenced by LOG_SET_THRESHOLD().
| #define LOGARGS_DIAG_PLAIN | ( | level, | |
| fmt, | |||
| ... | |||
| ) |
Standard diagnostic logging output arguments in plain text.
| level | Loggging level. |
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 279 of file log.h.
Referenced by LOG_SET_THRESHOLD().
| #define LOGARGS_ERR | ( | fmt, | |
| ... | |||
| ) |
Standard error logging output arguments with compiled color.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
| #define LOGARGS_ERR_PLAIN | ( | fmt, | |
| ... | |||
| ) | LOG_PREFACE_PLAIN "Error: %s[%d] " fmt, __FILE__, __LINE__, ##__VA_ARGS__ |
| #define LOGARGS_SYSERR | ( | fmt, | |
| ... | |||
| ) |
Standard system error logging output arguments with compiled color.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
| #define LOGARGS_SYSERR_PLAIN | ( | fmt, | |
| ... | |||
| ) |
Standard system error logging output arguments with compiled color.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
| #define LOGARGS_WARN | ( | fmt, | |
| ... | |||
| ) |
Standard warning logging output arguments with compiled color.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
| #define LOGARGS_WARN_PLAIN | ( | fmt, | |
| ... | |||
| ) | LOG_PREFACE_PLAIN "Warning: %s[%d] " fmt, __FILE__, __LINE__, ##__VA_ARGS__ |
| #define LOGDIAG | ( | level, | |
| fmt, | |||
| ... | |||
| ) |
Standard Diagnostic logging.
| level | Loggging level. |
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
| #define LOGDIAG1 | ( | fmt, | |
| ... | |||
| ) | LOGDIAG(LOG_LEVEL_DIAG1, fmt, ##__VA_ARGS__) |
Standard Diagnostic Level 1 logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 407 of file log.h.
Referenced by init(), LOG_SET_LOGFILE(), runExample(), and threadmain().
| #define LOGDIAG1CALL | ( | ... | ) | LOGDIAGCALL(LOG_LEVEL_DIAG1, ##__VA_ARGS__) |
Standard Diagnostic Level 1 function call tracing.
| ... | Optional argument_format,argument pairs. |
Definition at line 460 of file log.h.
Referenced by logtest_num1().
| #define LOGDIAG2 | ( | fmt, | |
| ... | |||
| ) | LOGDIAG(LOG_LEVEL_DIAG2, fmt, ##__VA_ARGS__) |
Standard Diagnostic Level 2 logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 400 of file log.h.
Referenced by logtest_num1().
| #define LOGDIAG2CALL | ( | ... | ) | LOGDIAGCALL(LOG_LEVEL_DIAG2, ##__VA_ARGS__) |
Standard Diagnostic Level 2 function call tracing.
| ... | Optional argument_format,argument pairs. |
Definition at line 454 of file log.h.
Referenced by logtest_num2().
| #define LOGDIAG3 | ( | fmt, | |
| ... | |||
| ) | LOGDIAG(LOG_LEVEL_DIAG3, fmt, ##__VA_ARGS__) |
Standard Diagnostic Level 3 logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 393 of file log.h.
Referenced by ConfigDbNew(), shm_close(), shm_mutex_init(), shm_open(), and SocketAttrSetNonBlocking().
| #define LOGDIAG3CALL | ( | ... | ) | LOGDIAGCALL(LOG_LEVEL_DIAG3, ##__VA_ARGS__) |
| #define LOGDIAG4 | ( | fmt, | |
| ... | |||
| ) | LOGDIAG(LOG_LEVEL_DIAG4, fmt, ##__VA_ARGS__) |
Standard Diagnostic Level 4 logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 386 of file log.h.
Referenced by ConfigDbRead(), ConfigDbReadFp(), ConfigDelete(), ConfigSetStr(), DListVoidAppend(), DListVoidInsert(), DListVoidNew(), DListVoidPrepend(), grow_table(), hash_table_create(), hash_table_init(), init_hash_sizes(), logtest_num2(), NewSearchPathDList(), NewSearchPathExpanded(), SearchPathIterFirst(), SearchPathIterNext(), shm_mutex_create(), shrink_table(), SocketAccept(), SocketClose(), SocketOpenTcpConnection(), SocketOpenTcpListener(), SocketOpenUdp(), SocketRead(), and SocketWriteAll().
| #define LOGDIAG4CALL | ( | ... | ) | LOGDIAGCALL(LOG_LEVEL_DIAG4, ##__VA_ARGS__) |
Standard Diagnostic Level 4 function call tracing.
| ... | Optional argument_format,argument pairs. |
Definition at line 442 of file log.h.
Referenced by ConfigDbDelete(), ConfigDbNew(), ConfigDbRead(), ConfigDbReadFp(), ConfigSectionDelete(), ConfigSectionNew(), ConfigSetStr(), DListVoidAppend(), DListVoidDelete(), DListVoidDeleteAllNodes(), DListVoidDeleteNode(), DListVoidDeleteNodeAt(), DListVoidFindNode(), DListVoidGetNodeAt(), DListVoidInsert(), DListVoidNew(), DListVoidPrepend(), DListVoidUnlinkDataAt(), DListVoidUnlinkNodeAt(), grow_table(), hash_node_fast_unlink(), hash_node_insert(), hash_node_unlink(), hash_table_create(), hash_table_destroy(), hash_table_init(), shrink_table(), SocketAccept(), SocketOpenTcpListener(), SocketOpenUdp(), SockSetAdd(), and SockSetRemove().
| #define LOGDIAG5 | ( | fmt, | |
| ... | |||
| ) | LOGDIAG(LOG_LEVEL_DIAG5, fmt, ##__VA_ARGS__) |
| #define LOGDIAG5CALL | ( | ... | ) | LOGDIAGCALL(LOG_LEVEL_DIAG5, ##__VA_ARGS__) |
| #define LOGDIAGCALL | ( | level, | |
| ... | |||
| ) |
Standard Diagnostic function call tracing.
| level | Loggging level. |
| ... | Optional argument_format,argument pairs. |
| #define LOGERROR | ( | fmt, | |
| ... | |||
| ) |
Standard Error logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 488 of file log.h.
Referenced by ConfigDbNew(), ConfigDbReadFp(), ConfigGetDouble(), ConfigGetLong(), ConfigSectionDelete(), ConfigSectionNew(), DListVoidDeleteNode(), DListVoidGetNodeAt(), logtest_num2(), main(), NewJoinedPath(), NewSearchPathDList(), NewSearchPathExpanded(), OptsPrintf(), runExample(), runlogtests(), SearchPathIterFirst(), SearchPathIterNew(), shm_close(), shm_mutex_init(), shm_mutex_lock(), shm_mutex_trylock(), shm_mutex_unlock(), shm_open(), SocketAccept(), SocketOpenTcpConnection(), SocketOpenTcpListener(), SocketOpenUdp(), SocketRead(), SocketThisHostName(), SocketWrite(), SocketWriteAll(), SockResolveHostName(), SockSetChkSd(), and SockSetSelect().
| #define LOGNS |
| #define LOGNS_NAME "" |
| #define LOGSYSERROR | ( | fmt, | |
| ... | |||
| ) |
Standard System Error logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 509 of file log.h.
Referenced by ConfigDbRead(), createThreads(), LOG_SET_LOGFILE(), logtest_num2(), shm_close(), shm_mutex_create(), shm_mutex_init(), shm_open(), SocketAccept(), SocketAddrNameInet(), SocketAttrSetLocalName(), SocketAttrSetNonBlocking(), SocketClose(), SocketOpenTcpConnection(), SocketOpenTcpListener(), SocketOpenUdp(), SocketRead(), SocketThisHostName(), SocketWrite(), and SockSetSelect().
| #define LOGUSER | ( | level, | |
| fmt, | |||
| ... | |||
| ) | LOGDIAG(level+LOG_LEVEL_DIAG3+1, fmt, ##__VA_ARGS__) |
| #define LOGWARN | ( | fmt, | |
| ... | |||
| ) |
Standard Warning logging.
| fmt | Optional specifics format string. |
| ... | Optional specific variable arguments for fmt. |
Definition at line 467 of file log.h.
Referenced by logtest_num2().