fehQlibs 26
Qlibs
Loading...
Searching...
No Matches
Macros | Functions
logmsg.h File Reference
#include <errno.h>
#include <stdlib.h>
#include "error.h"
Include dependency graph for logmsg.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define err_sys(w, e)   logmsg(w,e,FATAL,"")
 
#define err_sys_plus(w, e, m)   logmsg(w,e,FATAL,m)
 
#define err_tmp(w, e, m)   logmsg(w,e,WARN,m)
 
#define err_tmp_plus(w, e, m)   logmsg(w,e,WARN,m)
 
#define err_int(w, e, c)   logmsg(w,e,c,"")
 
#define err_int_plus(w, e, c, m)   logmsg(w,e,c,m)
 
#define log_who(w, m)   logmsg(w,0,LOG,m)
 
#define log_anon(m)   logmsg("",0,LOG,m)
 
#define log_cat(n)   logmsg("",0,CAT,m)
 
#define B(...)   build_log_msg((const char *[]){__VA_ARGS__,NULL})
 

Functions

void logmsg (const char *who, int ecode, unsigned int class, const char *msg)
 
char * build_log_msg (const char *[])
 

Macro Definition Documentation

◆ B

#define B (   ...)    build_log_msg((const char *[]){__VA_ARGS__,NULL})

Definition at line 29 of file logmsg.h.

◆ err_int

#define err_int (   w,
  e,
 
)    logmsg(w,e,c,"")

Definition at line 19 of file logmsg.h.

◆ err_int_plus

#define err_int_plus (   w,
  e,
  c,
 
)    logmsg(w,e,c,m)

Definition at line 20 of file logmsg.h.

◆ err_sys

#define err_sys (   w,
 
)    logmsg(w,e,FATAL,"")

Definition at line 13 of file logmsg.h.

◆ err_sys_plus

#define err_sys_plus (   w,
  e,
 
)    logmsg(w,e,FATAL,m)

Definition at line 14 of file logmsg.h.

◆ err_tmp

#define err_tmp (   w,
  e,
 
)    logmsg(w,e,WARN,m)

Definition at line 16 of file logmsg.h.

◆ err_tmp_plus

#define err_tmp_plus (   w,
  e,
 
)    logmsg(w,e,WARN,m)

Definition at line 17 of file logmsg.h.

◆ log_anon

#define log_anon (   m)    logmsg("",0,LOG,m)

Definition at line 24 of file logmsg.h.

◆ log_cat

#define log_cat (   n)    logmsg("",0,CAT,m)

Definition at line 25 of file logmsg.h.

◆ log_who

#define log_who (   w,
 
)    logmsg(w,0,LOG,m)

Definition at line 23 of file logmsg.h.

Function Documentation

◆ build_log_msg()

char * build_log_msg ( const char *  x[])

Definition at line 19 of file logmsg.c.

Here is the call graph for this function:

◆ logmsg()

void logmsg ( const char *  who,
int  ecode,
unsigned int  class,
const char *  msg 
)

Definition at line 30 of file logmsg.c.

Here is the call graph for this function: