5755523 [rkeene@sledge /home/rkeene/devel/cygwin-stuff/cyg-root/usr/include/sys]$ cat -n syslog.h
 1 #ifndef _SYS_LOG_H
 2 #define _SYS_LOG_H
 3 
 4 #include <sys/cdefs.h>
 5 #define LOG_EMERG   0
 6 #define LOG_ALERT   1
 7 #define LOG_CRIT    2
 8 #define LOG_ERR     3
 9 #define LOG_WARNING 4
10 #define LOG_NOTICE  5
11 #define LOG_INFO    6
12 #define LOG_DEBUG   7
13 
14 #define LOG_PRIMASK 0x07
15 
16 #define LOG_PRI(p)  ((p) & LOG_PRIMASK)
17 #define LOG_MAKEPRI(fac, pri)   (((fac) << 3) | (pri))
18 
19 #define LOG_KERN    (0<<3)
20 #define LOG_USER    (1<<3)
21 #define LOG_MAIL    (2<<3)
22 #define LOG_DAEMON  (3<<3)
23 #define LOG_AUTH    (4<<3)
24 #define LOG_SYSLOG  (5<<3)
25 #define LOG_LPR     (6<<3)
26 #define LOG_NEWS    (7<<3)
27 #define LOG_UUCP    (8<<3)
28 #define LOG_CRON    (9<<3)
29 #define LOG_AUTHPRIV    (10<<3)
30 #define LOG_FTP     (11<<3)
31 
32 /* Codes through 15 are reserved for system use */
33 #define LOG_LOCAL0  (16<<3)
34 #define LOG_LOCAL1  (17<<3)
35 #define LOG_LOCAL2  (18<<3)
36 #define LOG_LOCAL3  (19<<3)
37 #define LOG_LOCAL4  (20<<3)
38 #define LOG_LOCAL5  (21<<3)
39 #define LOG_LOCAL6  (22<<3)
40 #define LOG_LOCAL7  (23<<3)
41 
42 #define LOG_NFACILITIES 24
43 #define LOG_FACMASK 0x03f8
44 #define LOG_FAC(p)  (((p) & LOG_FACMASK) >> 3)
45 
46 #define LOG_MASK(pri)   (1 << (pri))
47 #define LOG_UPTO(pri)   ((1 << ((pri)+1)) - 1)
48 
49 /*
50  * Option flags for openlog.
51  *
52  * LOG_ODELAY no longer does anything.
53  * LOG_NDELAY is the inverse of what it used to be.
54  */
55 #define LOG_PID         0x01    /* log the pid with each message */
56 #define LOG_CONS        0x02    /* log on the console if errors in sending */
57 #define LOG_ODELAY      0x04    /* delay open until first syslog() (default) */
58 #define LOG_NDELAY      0x08    /* don't delay open */
59 #define LOG_NOWAIT      0x10    /* don't wait for console forks: DEPRECATED */
60 #define LOG_PERROR      0x20    /* log to stderr as well */
61 
62 __BEGIN_DECLS
63 
64 
65 void    closelog (void);
66 void    openlog (const char *, int, int);
67 int setlogmask (int);
68 void    syslog (int, const char *, ...);
69 
70 __END_DECLS
71 
72 
73 #endif /* _SYS_LOG_H */
5755524 [rkeene@sledge /home/rkeene/devel/cygwin-stuff/cyg-root/usr/include/sys]$

Click here to go back to the directory listing.
Click here to download this file.
last modified: 2001-01-31 15:09:12