|
@ -1,4 +1,4 @@ |
|
|
/* $OpenBSD: client.c,v 1.59 2005/04/18 11:06:35 henning Exp $ */ |
|
|
|
|
|
|
|
|
/* $OpenBSD: client.c,v 1.60 2005/04/19 11:08:41 henning Exp $ */ |
|
|
|
|
|
|
|
|
/* |
|
|
/* |
|
|
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> |
|
|
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> |
|
@ -268,14 +268,14 @@ client_dispatch(struct ntp_peer *p, u_int8_t settime) |
|
|
p->trustlevel++; |
|
|
p->trustlevel++; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
client_update(p); |
|
|
|
|
|
if (settime) |
|
|
|
|
|
priv_settime(p->reply[p->shift].offset); |
|
|
|
|
|
|
|
|
|
|
|
log_debug("reply from %s: offset %f delay %f, " |
|
|
log_debug("reply from %s: offset %f delay %f, " |
|
|
"next query %ds", log_sockaddr((struct sockaddr *)&p->addr->ss), |
|
|
"next query %ds", log_sockaddr((struct sockaddr *)&p->addr->ss), |
|
|
p->reply[p->shift].offset, p->reply[p->shift].delay, interval); |
|
|
p->reply[p->shift].offset, p->reply[p->shift].delay, interval); |
|
|
|
|
|
|
|
|
|
|
|
client_update(p); |
|
|
|
|
|
if (settime) |
|
|
|
|
|
priv_settime(p->reply[p->shift].offset); |
|
|
|
|
|
|
|
|
if (++p->shift >= OFFSET_ARRAY_SIZE) |
|
|
if (++p->shift >= OFFSET_ARRAY_SIZE) |
|
|
p->shift = 0; |
|
|
p->shift = 0; |
|
|
|
|
|
|
|
|