diff options
author | Henning Brauer <henning@cvs.openbsd.org> | 2004-10-24 18:47:44 +0000 |
---|---|---|
committer | Henning Brauer <henning@cvs.openbsd.org> | 2004-10-24 18:47:44 +0000 |
commit | cf1a2ee914763195a96d2bebbde5d5374f3f71b9 (patch) | |
tree | e32da1b7b5cff180343f1823712cc59d5bcf433e | |
parent | cf78524e340afcef24865a5975e60a6f4e766aec (diff) |
accept replies with a NTP version number of 4 or lower, instead of only 4
as before, we can handle all versions
-rw-r--r-- | usr.sbin/rdate/ntp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/rdate/ntp.c b/usr.sbin/rdate/ntp.c index 3d2a7a47810..5d59c3b18ae 100644 --- a/usr.sbin/rdate/ntp.c +++ b/usr.sbin/rdate/ntp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ntp.c,v 1.25 2004/09/15 01:11:12 henning Exp $ */ +/* $OpenBSD: ntp.c,v 1.26 2004/10/24 18:47:43 henning Exp $ */ /* * Copyright (c) 1996, 1997 by N.M. Maclaren. All rights reserved. @@ -354,9 +354,9 @@ retry: return (1); } - if (data->version != NTP_VERSION) { - warnx("Received different NTP version than sent," - "packet rejected"); + if (data->version > NTP_VERSION) { + warnx("Received NTP version %u, need %u or lower", + data->version, NTP_VERSION); return (1); } |