1 /* $OpenBSD: log.h,v 1.3 2021/12/13 18:28:40 deraadt Exp $ */ 2 3 #ifndef _LOG_H 4 #define _LOG_H 1 5 6 #include <stdarg.h> /* for va_list */ 7 8 extern int log_debug_use_syslog; 9 10 __BEGIN_DECLS 11 void log_init (int); 12 void logit(int, const char *, ...) 13 __attribute__((__format__ (__syslog__, 2, 3))); 14 void vlog(int, const char *, va_list) 15 __attribute__((__format__ (__syslog__, 2, 0))); 16 void log_warn(const char *, ...) 17 __attribute__((__format__ (printf, 1, 2))); 18 void log_warnx(const char *, ...) 19 __attribute__((__format__ (printf, 1, 2))); 20 void log_info(const char *, ...) 21 __attribute__((__format__ (printf, 1, 2))); 22 void log_debug(const char *, ...) 23 __attribute__((__format__ (printf, 1, 2))); 24 __dead void fatal(const char *); 25 __dead void fatalx(const char *); 26 __END_DECLS 27 28 #endif 29