syslog
This commit is contained in:
@ -118,15 +118,7 @@ int logMsg(const char *format, ...) {
|
||||
return res;
|
||||
}
|
||||
|
||||
int errMsg(const char *format, ...) {
|
||||
va_list vl;
|
||||
va_start(vl, format);
|
||||
int res = innerLogMsg("\x1b[31;1m", "\x1b[0m\r\n", true, format, vl);
|
||||
va_end(vl);
|
||||
return res;
|
||||
}
|
||||
|
||||
int coloredMsg(const t_logColor color, const char *format, ...) {
|
||||
int coloredMsg(const t_logColor color, bool syslogToo, const char *format, ...) {
|
||||
const static char POST[] = "\x1b[0m\r\n";
|
||||
const static char HIGH[] = "\x1b[1m";
|
||||
const static char RED[] = "\x1b[31;1m";
|
||||
@ -153,7 +145,7 @@ int coloredMsg(const t_logColor color, const char *format, ...) {
|
||||
}
|
||||
va_list vl;
|
||||
va_start(vl, format);
|
||||
int res = innerLogMsg(pre, POST, false, format, vl);
|
||||
int res = innerLogMsg(pre, POST, syslogToo, format, vl);
|
||||
va_end(vl);
|
||||
return res;
|
||||
}
|
||||
|
Reference in New Issue
Block a user