summaryrefslogtreecommitdiff
path: root/sbin/dhclient/dhclient.c
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2017-08-26 14:45:58 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2017-08-26 14:45:58 +0000
commit1df2b32a9e6308e38c72697b3eac01c533bbe4ab (patch)
tree715d83507dfdb2e953ed6849a07cd30cbef865df /sbin/dhclient/dhclient.c
parentcc73752fcb0b6a75e545d75b31b83111691ffa4f (diff)
Make log_debug() more likely to do something by
calling log_setverbose(1) when DEBUG is defined.
Diffstat (limited to 'sbin/dhclient/dhclient.c')
-rw-r--r--sbin/dhclient/dhclient.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sbin/dhclient/dhclient.c b/sbin/dhclient/dhclient.c
index 4d4718d74d7..2795dbc73ee 100644
--- a/sbin/dhclient/dhclient.c
+++ b/sbin/dhclient/dhclient.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dhclient.c,v 1.495 2017/08/23 08:50:56 jca Exp $ */
+/* $OpenBSD: dhclient.c,v 1.496 2017/08/26 14:45:57 krw Exp $ */
/*
* Copyright 2004 Henning Brauer <henning@openbsd.org>
@@ -1985,7 +1985,11 @@ go_daemon(void)
/* Stop logging to stderr. */
log_perror = 0;
log_init(0, LOG_DAEMON);
+#ifdef DEBUG
+ log_setverbose(1);
+#else
log_setverbose(0);
+#endif /* DEBUG */
if (rdaemon(nullfd) == -1)
fatal("Cannot daemonize");