Go to the source code of this file.
Data Structures | |
struct | klog_args_s |
struct | klog_mem_msg_s |
struct | klog_mem_s |
struct | klog_file_s |
struct | klog_syslog_s |
struct | klog_s |
Defines | |
#define | KLOG_FACILITY_UNKNOWN -1 |
#define | KLOG_LN_SZ 512 |
#define | KLOG_ID_SZ 8 |
#define | KLOG_MLIMIT_DFL 250 |
#define | KLOG_FLIMIT_DFL 250 |
#define | KLOG_FSPLITS_DFL 4 |
#define | KLOG_MEM_FULL(klm) ((klm)->nmsgs >= (klm)->bound) |
#define | KLOG_PAGE_FULL(klf) ((klf)->offset >= (klf)->nlines) |
#define | IS_KLOG_TYPE(t) (t >= KLOG_TYPE_MEM && t <= KLOG_TYPE_SYSLOG) |
Typedefs | |
typedef klog_args_s | klog_args_t |
typedef klog_mem_msg_s | klog_mem_msg_t |
typedef klog_mem_s | klog_mem_t |
typedef klog_file_s | klog_file_t |
typedef klog_syslog_s | klog_syslog_t |
typedef klog_s | klog_t |
Enumerations | |
enum | { KLOG_DEBUG, KLOG_INFO, KLOG_NOTICE, KLOG_WARNING, KLOG_ERR, KLOG_CRIT, KLOG_ALERT, KLOG_EMERG, KLOG_LEVEL_UNKNOWN } |
Functions | |
int | klog_open (klog_args_t *ka, klog_t **pkl) |
Create a new klog_t object from the corresponding klog_args_t . | |
int | klog (klog_t *kl, int level, const char *msg,...) |
Log a KLOG message. | |
void | klog_close (klog_t *kl) |
Destroy a klog_t object. | |
int | klog_flush (klog_t *kl) |
flush all buffered data to the klog_t (file) device | |
int | klog_getln (klog_t *kl, size_t nth, char ln[]) |
Return the nth memory-log message. | |
ssize_t | klog_countln (klog_t *kl) |
Count the number of lines in the supplied memory-log context kl . | |
int | klog_clear (klog_t *kl) |
Remove all memory-log messages from the supplied klog_t context. | |
int | klog_args (u_config_t *logsect, klog_args_t **pka) |
create a klog_args_t object with configuration parameters read from a log subsection of a kloned configuration file | |
void | klog_args_free (klog_args_t *ka) |
int | klog_open_from_config (u_config_t *ls, klog_t **pkl) |
create a klog_t object reading configuration parameters from a configuration "log" record |
|
Definition at line 112 of file klog.h. Referenced by klog(), klog_clear(), klog_close(), klog_countln(), klog_flush(), and klog_getln(). |
|
|
|
|
|
|
|
Definition at line 53 of file klog.h. Referenced by klog_new(). |
|
Definition at line 52 of file klog.h. Referenced by server_ppc_cmd_log_get(). |
|
|
|
|
|
|
|
Definition at line 50 of file klog.h. Referenced by klog_args(), klog_args_free(), klog_args_print(), klog_open(), and klog_open_from_config(). |
|
Definition at line 92 of file klog.h. Referenced by klog_open_file(). |
|
|
|
Definition at line 79 of file klog.h. Referenced by klog_open_mem(). |
|
Definition at line 101 of file klog.h. Referenced by klog_open_syslog(). |
|
Definition at line 134 of file klog.h. Referenced by klog(), klog_clear(), klog_close(), klog_countln(), klog_flush(), klog_getln(), klog_new(), klog_open(), klog_open_file(), klog_open_from_config(), klog_open_mem(), klog_open_syslog(), server_foreach_memlog_line(), server_get_logger(), server_ppc_cb_log_add(), and server_ppc_cb_log_get(). |
|
|
|
Definition at line 149 of file klog.c. References klog_s::cb_log, IS_KLOG_TYPE, KLOG_LEVEL_UNKNOWN, klog_t, klog_s::threshold, and klog_s::type. Referenced by server_ppc_cb_log_add(). |
|
Definition at line 37 of file klog.c. References klog_args_s::fbasename, klog_args_s::flimit, klog_args_s::fsplits, klog_args_s::ident, klog_args_free(), klog_args_t, klog_args_s::mlimit, klog_args_s::sfacility, klog_args_s::soptions, klog_args_s::threshold, and klog_args_s::type. Referenced by klog_open_from_config(). |
|
Definition at line 339 of file klog.c. References klog_args_s::fbasename, klog_args_s::ident, and klog_args_t. Referenced by klog_args(), and klog_open_from_config(). |
|
Definition at line 232 of file klog.c. References klog_s::cb_clear, IS_KLOG_TYPE, klog_t, and klog_s::type. |
|
Definition at line 184 of file klog.c. References klog_s::cb_close, IS_KLOG_TYPE, klog_t, and klog_s::type. Referenced by backend_free(), klog_open(), klog_open_from_config(), and server_free(). |
|
Definition at line 250 of file klog.c. References klog_s::cb_countln, IS_KLOG_TYPE, klog_t, and klog_s::type. |
|
Definition at line 307 of file klog.c. References klog_s::cb_flush, IS_KLOG_TYPE, klog_t, and klog_s::type. Referenced by server_loop(). |
|
Definition at line 212 of file klog.c. References klog_s::cb_getln, IS_KLOG_TYPE, klog_t, and klog_s::type. Referenced by server_ppc_cb_log_get(). |
|
Definition at line 96 of file klog.c. References klog_args_s::fbasename, klog_args_s::flimit, klog_args_s::fsplits, klog_args_s::ident, klog_args_t, klog_close(), klog_new(), klog_open_file(), klog_open_mem(), klog_open_syslog(), klog_t, klog_args_s::mlimit, klog_args_s::sfacility, klog_args_s::soptions, klog_args_s::threshold, and klog_args_s::type. Referenced by klog_open_from_config(). |
|
Definition at line 272 of file klog.c. References klog_args(), klog_args_free(), klog_args_t, klog_close(), klog_open(), and klog_t. Referenced by server_create(). |