xref: /haiku/headers/private/syslog_daemon/syslog_daemon.h (revision 0edba5de96c0d442a1733388d6be98bab3967750)
1 /*
2 ** Copyright 2003, Axel Dörfler, axeld@pinc-software.de. All rights reserved.
3 ** Distributed under the terms of the OpenBeOS License.
4 */
5 #ifndef SYSLOG_DAEMON_H
6 #define SYSLOG_DAEMON_H
7 
8 
9 #include <OS.h>
10 
11 
12 #define SYSLOG_PORT_NAME	"syslog_daemon"
13 #define SYSLOG_MESSAGE		'_Syl'
14 
15 // This message is sent from both, the POSIX syslog API and the kernel's
16 // dprintf() logging facility if logging to syslog was enabled.
17 
18 struct syslog_message {
19 	thread_id	from;
20 	time_t		when;
21 	int32		options;
22 	int16		priority;
23 	char		ident[B_OS_NAME_LENGTH];
24 	char		message[1];
25 };
26 
27 #define SYSLOG_PRIORITY(options)	((options) & 0x7)
28 #define SYSLOG_FACILITY(options)	((options) & 0x03f8)
29 
30 #endif	/* SYSLOG_DAEMON_H */
31