diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2001-07-07 18:26:23 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2001-07-07 18:26:23 +0000 |
commit | bca8ede36193523f5e509e218d1976dc9b8386e2 (patch) | |
tree | 8021052d902e951ea77cf9a839e25b3062a6b5bc /sbin/routed | |
parent | f450dee1afdaa407e9eb35b9d02efd9642a245fa (diff) |
major -Wall cleanup, almost complete
Diffstat (limited to 'sbin/routed')
-rw-r--r-- | sbin/routed/main.c | 9 | ||||
-rw-r--r-- | sbin/routed/output.c | 6 | ||||
-rw-r--r-- | sbin/routed/table.c | 4 |
3 files changed, 10 insertions, 9 deletions
diff --git a/sbin/routed/main.c b/sbin/routed/main.c index 3b590f05da8..2ff8bb2cc55 100644 --- a/sbin/routed/main.c +++ b/sbin/routed/main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: main.c,v 1.11 2001/06/13 20:13:29 markus Exp $ */ +/* $OpenBSD: main.c,v 1.12 2001/07/07 18:26:20 deraadt Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -39,7 +39,7 @@ char copyright[] = #if !defined(lint) static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 6/5/93"; #else -static char rcsid[] = "$OpenBSD: main.c,v 1.11 2001/06/13 20:13:29 markus Exp $"; +static char rcsid[] = "$OpenBSD: main.c,v 1.12 2001/07/07 18:26:20 deraadt Exp $"; #endif #include "defs.h" @@ -47,9 +47,10 @@ static char rcsid[] = "$OpenBSD: main.c,v 1.11 2001/06/13 20:13:29 markus Exp $" #ifdef sgi #include "math.h" #endif -#include <signal.h> -#include <fcntl.h> #include <sys/file.h> +#include <fcntl.h> +#include <err.h> +#include <signal.h> pid_t mypid; diff --git a/sbin/routed/output.c b/sbin/routed/output.c index a19872cb17c..06abe9370e2 100644 --- a/sbin/routed/output.c +++ b/sbin/routed/output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: output.c,v 1.6 2001/01/05 05:23:46 angelos Exp $ */ +/* $OpenBSD: output.c,v 1.7 2001/07/07 18:26:20 deraadt Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -36,7 +36,7 @@ #if !defined(lint) static char sccsid[] = "@(#)output.c 8.1 (Berkeley) 6/5/93"; #else -static char rcsid[] = "$OpenBSD: output.c,v 1.6 2001/01/05 05:23:46 angelos Exp $"; +static char rcsid[] = "$OpenBSD: output.c,v 1.7 2001/07/07 18:26:20 deraadt Exp $"; #endif #include "defs.h" @@ -96,7 +96,7 @@ output(enum output_type type, { struct sockaddr_in sin; int flags; - char *msg; + char *msg = NULL; int res; naddr tgt_mcast; int soc; diff --git a/sbin/routed/table.c b/sbin/routed/table.c index 7354e264191..d19310b51d5 100644 --- a/sbin/routed/table.c +++ b/sbin/routed/table.c @@ -1,4 +1,4 @@ -/* $OpenBSD: table.c,v 1.5 1997/07/30 23:28:45 deraadt Exp $ */ +/* $OpenBSD: table.c,v 1.6 2001/07/07 18:26:20 deraadt Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -1674,7 +1674,7 @@ rtswitch(struct rt_entry *rt, return; swap = rt->rt_spares[0]; - (void)sprintf(label, "Use #%d", rts - rt->rt_spares); + (void)sprintf(label, "Use #%d", (int)(rts - rt->rt_spares)); rtchange(rt, rt->rt_state & ~(RS_NET_SYN | RS_RDISC), rts->rts_gate, rts->rts_router, rts->rts_metric, rts->rts_tag, rts->rts_ifp, rts->rts_time, label); |