0
0
mirror of https://gitlab.nic.cz/labs/bird.git synced 2024-09-18 19:35:20 +00:00
Commit Graph

73 Commits

Author SHA1 Message Date
Ondrej Zajicek
cb53039271 Rate limit for most abundant log messages 2009-02-26 14:23:54 +01:00
Martin Mares
e98bc2ea9b Renamed log() to log_msg(), but still keeping the old name as a macro.
This is done to avoid clashes with gcc-3.3 which has built-in logarithms :)
2004-06-05 09:05:12 +00:00
Martin Mares
5da8f82feb A better comment. 2004-06-05 09:01:12 +00:00
Ondrej Filip
7fdd338c36 ALIGN -> BIRD_ALIGN 2004-06-01 10:28:25 +00:00
Martin Mares
206f59dfa8 Added UNUSED. 2004-05-31 21:02:09 +00:00
Ondrej Filip
d93fb7e6b9 #ifndef ALIGN - it is defined on *BSD 2004-05-31 13:58:38 +00:00
Martin Mares
47f18ac39a ABS should be a macro. 2002-11-13 08:47:19 +00:00
Martin Mares
27e993fb4e Fixed duplicity in log category numbering.
Thanks to Zheng Yuan for spotting this.
2001-02-20 09:49:19 +00:00
Martin Mares
7750634946 Introduced `ARRAY_SIZE' macro to replace all the sizeof(a)/sizeof(*a) constructs. 2000-04-12 13:21:23 +00:00
Martin Mares
e68dd11c43 Use do { } while(0) instead of empty DBG if not debugging. 2000-03-12 21:47:25 +00:00
Martin Mares
3cbfcafecd DBG calls debug() if defined(LOCAL_DEBUG) || defined(GLOBAL_DEBUG). 2000-03-07 21:04:14 +00:00
Martin Mares
a0c37b45e5 Logging is now configurable. You can define multiple log outputs (to both
files and syslog) and assign lists of message categories to each of them.
1999-12-06 13:45:56 +00:00
Martin Mares
f651941402 Added a function for generating 32-bit random numbers. 1999-08-17 20:47:40 +00:00
Martin Mares
6134024815 #define NULL if not defined by system includes. 1999-03-29 19:13:36 +00:00
Martin Mares
c4c63eecc3 Added several parentheses to MIN/MAX macros. 1999-02-05 21:29:19 +00:00
Martin Mares
98e87c8628 Finer grained logging levels:
#define L_DEBUG "\001"   /* Debugging messages */
#define L_INFO "\002"    /* Informational messages */
#define L_WARN "\003"    /* Warnings */
#define L_ERR "\004"     /* Errors */
#define L_AUTH "\005"    /* Authorization failed etc. */
#define L_FATAL "\006"   /* Fatal errors */
#define L_TRACE "\002"   /* Protocol tracing */
#define L_INFO "\003"    /* Informational messages */
#define L_REMOTE "\004"  /* Remote protocol errors */
#define L_WARN "\004"    /* Local warnings */
#define L_ERR "\005"     /* Local errors */
#define L_AUTH "\006"    /* Authorization failed etc. */
#define L_FATAL "\007"   /* Fatal errors */
#define L_BUG "\010"     /* BIRD bugs */

Introduced bug() which is like die(), but with level L_BUG. Protocols
should _never_ call die() as it should be used only during initialization
and on irrecoverable catastrophic events like out of memory.

Also introduced ASSERT() which behaves like normal assert(), but it calls
bug() when assertion fails. When !defined(DEBUGGING), it gets ignored.
1998-12-20 14:24:35 +00:00
Martin Mares
1be52eea57 Removed format specification attributes for log() and debug() until
GCC is fixed to handle custom formats.
1998-07-10 08:39:34 +00:00
Pavel Machek
cf3527e2f4 Adding MIN()/MAX() macros 1998-07-09 19:36:05 +00:00
Martin Mares
5222c46ceb DBG now calls debug() instead of sending it to log(). 1998-05-26 21:36:17 +00:00
Martin Mares
25697773b5 The library is now glued together from generic and OS-dependent parts
by the `mergedirs' script. Few more IP address manipulation functions
and some fixes.
1998-05-15 07:56:13 +00:00
Martin Mares
18c8241a91 BIRD library: The story continues.
Complete resource manages and IP address handling.
1998-05-03 16:43:39 +00:00
Martin Mares
c40e05a0df Added IP address manipulation macros, interface declarations and logging. 1998-04-23 14:01:15 +00:00
Martin Mares
58ef912c6b First look at data structures. More to come tomorrow... 1998-04-22 12:58:34 +00:00