error: Add debug() function
Signed-off-by: Daniel Wagner <daniel.wagner@bmw-carit.de>
This commit is contained in:
parent
62a796727a
commit
bf246ba473
|
@ -10,6 +10,7 @@ void err_exit(int err, char *fmt, ...);
|
|||
void err_msg(char *fmt, ...);
|
||||
void err_msg_n(int err, char *fmt, ...);
|
||||
void err_quit(char *fmt, ...);
|
||||
void debug(char *fmt, ...);
|
||||
void info(char *fmt, ...);
|
||||
void warn(char *fmt, ...);
|
||||
void fatal(char *fmt, ...);
|
||||
|
|
|
@ -46,6 +46,16 @@ void err_quit(char *fmt, ...)
|
|||
exit(1);
|
||||
}
|
||||
|
||||
void debug(char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
va_start(ap, fmt);
|
||||
fputs("DEBUG: ", stderr);
|
||||
err_doit(0, fmt, ap);
|
||||
va_end(ap);
|
||||
}
|
||||
|
||||
void info(char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
|
Loading…
Reference in New Issue