summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2003-10-05 15:29:29 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2003-10-05 15:29:29 +0000
commitb24d2058bf434bf794f0f37c86db10369602d8f1 (patch)
treeb36fc949196f877f8e1832278b1c11cd87e2cf6f /usr.sbin
parent4305217087eb67458548b92ad1c06d2ceb930f41 (diff)
ansi
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/rtsold/dump.c10
-rw-r--r--usr.sbin/rtsold/if.c4
-rw-r--r--usr.sbin/rtsold/probe.c4
-rw-r--r--usr.sbin/rtsold/rtsol.c9
4 files changed, 13 insertions, 14 deletions
diff --git a/usr.sbin/rtsold/dump.c b/usr.sbin/rtsold/dump.c
index 2fa4c16e7d7..f8ac5e31474 100644
--- a/usr.sbin/rtsold/dump.c
+++ b/usr.sbin/rtsold/dump.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dump.c,v 1.10 2002/06/10 19:57:35 espie Exp $ */
+/* $OpenBSD: dump.c,v 1.11 2003/10/05 15:29:28 deraadt Exp $ */
/* $KAME: dump.c,v 1.10 2002/05/31 10:10:03 itojun Exp $ */
/*
@@ -55,7 +55,7 @@ static char *sec2str(time_t);
char *ifstatstr[] = {"IDLE", "DELAY", "PROBE", "DOWN", "TENTATIVE"};
static void
-dump_interface_status()
+dump_interface_status(void)
{
struct ifinfo *ifinfo;
struct timeval now;
@@ -94,8 +94,7 @@ dump_interface_status()
}
void
-rtsold_dump_file(dumpfile)
- char *dumpfile;
+rtsold_dump_file(char *dumpfile)
{
if ((fp = fopen(dumpfile, "w")) == NULL) {
warnmsg(LOG_WARNING, __func__, "open a dump file(%s): %s",
@@ -107,8 +106,7 @@ rtsold_dump_file(dumpfile)
}
static char *
-sec2str(total)
- time_t total;
+sec2str(time_t total)
{
static char result[256];
int days, hours, mins, secs;
diff --git a/usr.sbin/rtsold/if.c b/usr.sbin/rtsold/if.c
index 6b864a02995..7456c330ed7 100644
--- a/usr.sbin/rtsold/if.c
+++ b/usr.sbin/rtsold/if.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if.c,v 1.16 2003/05/15 14:40:53 itojun Exp $ */
+/* $OpenBSD: if.c,v 1.17 2003/10/05 15:29:28 deraadt Exp $ */
/* $KAME: if.c,v 1.18 2002/05/31 10:10:03 itojun Exp $ */
/*
@@ -67,7 +67,7 @@ static int get_llflag(const char *);
static void get_rtaddrs(int, struct sockaddr *, struct sockaddr **);
int
-ifinit()
+ifinit(void)
{
ifsock = rssock;
diff --git a/usr.sbin/rtsold/probe.c b/usr.sbin/rtsold/probe.c
index 7cef798c417..d6b42445863 100644
--- a/usr.sbin/rtsold/probe.c
+++ b/usr.sbin/rtsold/probe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: probe.c,v 1.9 2002/10/26 20:23:20 itojun Exp $ */
+/* $OpenBSD: probe.c,v 1.10 2003/10/05 15:29:28 deraadt Exp $ */
/* $KAME: probe.c,v 1.16 2002/06/10 20:00:36 itojun Exp $ */
/*
@@ -61,7 +61,7 @@ static int probesock;
static void sendprobe(struct in6_addr *, struct ifinfo *);
int
-probe_init()
+probe_init(void)
{
int scmsglen = CMSG_SPACE(sizeof(struct in6_pktinfo)) +
CMSG_SPACE(sizeof(int));
diff --git a/usr.sbin/rtsold/rtsol.c b/usr.sbin/rtsold/rtsol.c
index 900563dfacc..a280f653f39 100644
--- a/usr.sbin/rtsold/rtsol.c
+++ b/usr.sbin/rtsold/rtsol.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rtsol.c,v 1.9 2002/06/10 19:57:35 espie Exp $ */
+/* $OpenBSD: rtsol.c,v 1.10 2003/10/05 15:29:28 deraadt Exp $ */
/* $KAME: rtsol.c,v 1.15 2002/05/31 10:10:03 itojun Exp $ */
/*
@@ -70,7 +70,7 @@ int rssock;
static struct sockaddr_in6 sin6_allrouters = {sizeof(sin6_allrouters), AF_INET6};
int
-sockopen()
+sockopen(void)
{
static u_char *rcvcmsgbuf = NULL, *sndcmsgbuf = NULL;
int rcvcmsglen, sndcmsglen, on;
@@ -176,8 +176,8 @@ sendpacket(struct ifinfo *ifinfo)
struct in6_pktinfo *pi;
struct cmsghdr *cm;
int hoplimit = 255;
- int i;
struct sockaddr_in6 dst;
+ ssize_t i;
dst = sin6_allrouters;
dst.sin6_scope_id = ifinfo->linkid;
@@ -226,11 +226,12 @@ void
rtsol_input(int s)
{
u_char ntopbuf[INET6_ADDRSTRLEN], ifnamebuf[IFNAMSIZ];
- int ifindex = 0, i, *hlimp = NULL;
+ int ifindex = 0, *hlimp = NULL;
struct in6_pktinfo *pi = NULL;
struct ifinfo *ifi = NULL;
struct icmp6_hdr *icp;
struct cmsghdr *cm;
+ ssize_t i;
/* get message */
if ((i = recvmsg(s, &rcvmhdr, 0)) < 0) {