summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/notify-dns-slaves.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/notify-dns-slaves.c b/tools/notify-dns-slaves.c
index 7a334e9..e2c3325 100644
--- a/tools/notify-dns-slaves.c
+++ b/tools/notify-dns-slaves.c
@@ -179,6 +179,7 @@ vmessage(int level, int erno, const char* msg, va_list ap)
{
#define MAX_MSGLEN 1024
char buf[MAX_MSGLEN];
+ va_list ap2;
size_t len;
#if LOG_NORMAL
@@ -187,6 +188,7 @@ vmessage(int level, int erno, const char* msg, va_list ap)
#endif
assert (msg);
+ va_copy (ap2, ap);
strncpy (buf, msg, MAX_MSGLEN);
buf[MAX_MSGLEN - 1] = 0;
@@ -206,7 +208,7 @@ vmessage(int level, int erno, const char* msg, va_list ap)
#endif
vsyslog (level, buf, ap);
- vwarnx (buf, ap);
+ vwarnx (buf, ap2);
}
static void