Browse Source

when running ntpd with "-s" as it's argument from /etc/rc.conf, make sure the

output goes to syslog and not console by moving around log_init
OK henning@, markus@ and mblamer@
OPENBSD_3_9
wvdputte 19 years ago
parent
commit
33dc34f1c7
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/usr.sbin/ntpd/ntpd.c

+ 2
- 2
src/usr.sbin/ntpd/ntpd.c View File

@ -1,4 +1,4 @@
/* $OpenBSD: ntpd.c,v 1.39 2005/07/11 08:08:06 dtucker Exp $ */
/* $OpenBSD: ntpd.c,v 1.40 2005/09/06 21:27:10 wvdputte Exp $ */
/*
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@ -275,10 +275,10 @@ dispatch_imsg(struct ntpd_conf *conf)
fatalx("invalid IMSG_SETTIME received");
if (!conf->settime)
break;
log_init(conf->debug);
memcpy(&d, imsg.data, sizeof(d));
ntpd_settime(d);
/* daemonize now */
log_init(conf->debug);
if (!conf->debug)
if (daemon(1, 0))
fatal("daemon");


Loading…
Cancel
Save