From 0ad2e8b8058acc93dee5015a14089e6dc55f22e7 Mon Sep 17 00:00:00 2001 From: charnier Date: Sun, 6 Jul 2003 10:37:00 +0000 Subject: de-__P use port/proto to represent services (not proto/port). add FBSDID --- usr.sbin/timed/timed/timed.c | 19 ++++++++++--------- usr.sbin/timed/timedc/cmds.c | 17 +++++++++-------- 2 files changed, 19 insertions(+), 17 deletions(-) (limited to 'usr.sbin/timed') diff --git a/usr.sbin/timed/timed/timed.c b/usr.sbin/timed/timed/timed.c index 2daadb1..27344a3 100644 --- a/usr.sbin/timed/timed/timed.c +++ b/usr.sbin/timed/timed/timed.c @@ -37,13 +37,14 @@ static const char copyright[] = The Regents of the University of California. All rights reserved.\n"; #endif /* not lint */ -#ifndef lint #if 0 +#ifndef lint static char sccsid[] = "@(#)timed.c 8.1 (Berkeley) 6/6/93"; -#endif -static const char rcsid[] = - "$FreeBSD$"; #endif /* not lint */ +#endif + +#include +__FBSDID("$FreeBSD$"); #define TSPTYPES #include "globals.h" @@ -93,10 +94,10 @@ static struct goodhost { /* hosts that we trust */ } *goodhosts; static char *goodgroup; /* net group of trusted hosts */ -static void checkignorednets __P((void)); -static void pickslavenet __P((struct netinfo *)); -static void add_good_host __P((char *, int)); -static void usage __P((void)); +static void checkignorednets(void); +static void pickslavenet(struct netinfo *); +static void add_good_host(char *, int); +static void usage(void); /* * The timedaemons synchronize the clocks of hosts in a local area network. @@ -216,7 +217,7 @@ main(argc, argv) srvp = getservbyname("timed", "udp"); if (srvp == 0) - errx(1, "unknown service 'timed/udp'"); + errx(1, "timed/udp: unknown service"); port = srvp->s_port; bzero(&server, sizeof(struct sockaddr_in)); server.sin_port = srvp->s_port; diff --git a/usr.sbin/timed/timedc/cmds.c b/usr.sbin/timed/timedc/cmds.c index 35cc872..c6d6f07 100644 --- a/usr.sbin/timed/timedc/cmds.c +++ b/usr.sbin/timed/timedc/cmds.c @@ -31,13 +31,14 @@ * SUCH DAMAGE. */ -#ifndef lint #if 0 +#ifndef lint static char sccsid[] = "@(#)cmds.c 8.1 (Berkeley) 6/6/93"; -#endif -static const char rcsid[] = - "$FreeBSD$"; #endif /* not lint */ +#endif + +#include +__FBSDID("$FreeBSD$"); #include "timedc.h" #include @@ -188,7 +189,7 @@ clockdiff(argc, argv) /* get the address for the date ready */ sp = getservbyname(DATE_PORT, DATE_PROTO); if (!sp) { - warnx("%s/%s is an unknown service", DATE_PORT, DATE_PROTO); + warnx("%s/%s: unknown service", DATE_PORT, DATE_PROTO); dayaddr.sin_port = 0; } else { dayaddr.sin_port = sp->s_port; @@ -287,7 +288,7 @@ msite(argc, argv) srvp = getservbyname("timed", "udp"); if (srvp == 0) { - warnx("udp/timed: unknown service"); + warnx("timed/udp: unknown service"); return; } dest.sin_port = srvp->s_port; @@ -390,7 +391,7 @@ testing(argc, argv) srvp = getservbyname("timed", "udp"); if (srvp == 0) { - warnx("udp/timed: unknown service"); + warnx("timed/udp: unknown service"); return; } @@ -446,7 +447,7 @@ tracing(argc, argv) srvp = getservbyname("timed", "udp"); if (srvp == 0) { - warnx("udp/timed: unknown service"); + warnx("timed/udp: unknown service"); return; } dest.sin_port = srvp->s_port; -- cgit v1.1