]>
git.ipfire.org Git - thirdparty/bird.git/blob - client/util.c
2 * BIRD Client -- Utility Functions
4 * (c) 1999--2000 Martin Mares <mj@ucw.cz>
6 * Can be freely distributed and used under the terms of the GNU GPL.
13 #include "nest/bird.h"
14 #include "lib/string.h"
15 #include "client/client.h"
17 /* Client versions of logging functions */
20 vlog(const char *msg
, va_list args
)
24 int n
= vsnprintf(buf
, sizeof(buf
), msg
, args
);
26 snprintf(buf
, sizeof(buf
), "???");
28 snprintf(buf
+ sizeof(buf
) - 100, 100, " ... <too long>");
34 bug(const char *msg
, ...)
40 fputs("Internal error: ", stderr
);
42 vfprintf(stderr
, msg
, args
);
47 die(const char *msg
, ...)