summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2006-05-27 18:26:46 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2006-05-27 18:26:46 +0000
commit64201864bbe5387e655daaab298b9c47bd529f61 (patch)
tree0aae2ac07f25b4f3988e1503a16acc05094db819 /sbin
parent4935fbdf5d5c47f114f9d1b2b6a47dbc7b75a582 (diff)
Kill unused Aflag support that sneeked in via netstat code.
Diffstat (limited to 'sbin')
-rw-r--r--sbin/route/route.c4
-rw-r--r--sbin/route/show.c20
-rw-r--r--sbin/route/show.h4
3 files changed, 13 insertions, 15 deletions
diff --git a/sbin/route/route.c b/sbin/route/route.c
index 54d28920d70..5e204f88049 100644
--- a/sbin/route/route.c
+++ b/sbin/route/route.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: route.c,v 1.96 2006/05/21 13:27:08 mpf Exp $ */
+/* $OpenBSD: route.c,v 1.97 2006/05/27 18:26:45 claudio Exp $ */
/* $NetBSD: route.c,v 1.16 1996/04/15 18:27:05 cgd Exp $ */
/*
@@ -596,7 +596,7 @@ show(int argc, char *argv[])
usage(*argv);
}
- p_rttables(af, 0);
+ p_rttables(af);
}
void
diff --git a/sbin/route/show.c b/sbin/route/show.c
index 7063d31ba4f..30d1d4cbeba 100644
--- a/sbin/route/show.c
+++ b/sbin/route/show.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: show.c,v 1.51 2006/05/27 18:20:59 claudio Exp $ */
+/* $OpenBSD: show.c,v 1.52 2006/05/27 18:26:45 claudio Exp $ */
/* $NetBSD: show.c,v 1.1 1996/11/15 18:01:41 gwr Exp $ */
/*
@@ -101,8 +101,8 @@ static const struct bits bits[] = {
{ 0 }
};
-void pr_rthdr(int, int);
-void p_rtentry(struct rt_msghdr *, int);
+void pr_rthdr(int);
+void p_rtentry(struct rt_msghdr *);
void p_pfkentry(struct sadb_msg *);
void pr_family(int);
void p_encap(struct sockaddr *, struct sockaddr *, int);
@@ -118,7 +118,7 @@ void index_pfk(struct sadb_msg *, void **);
* Print routing tables.
*/
void
-p_rttables(int af, int Aflag)
+p_rttables(int af)
{
struct rt_msghdr *rtm;
struct sadb_msg *msg;
@@ -151,7 +151,7 @@ p_rttables(int af, int Aflag)
sa = (struct sockaddr *)(rtm + 1);
if (af != AF_UNSPEC && sa->sa_family != af)
continue;
- p_rtentry(rtm, Aflag);
+ p_rtentry(rtm);
}
free(buf);
buf = NULL;
@@ -206,10 +206,8 @@ p_rttables(int af, int Aflag)
* Print header for routing table columns.
*/
void
-pr_rthdr(int af, int Aflag)
+pr_rthdr(int af)
{
- if (Aflag)
- printf("%-*.*s ", PLEN, PLEN, "Address");
if (af != PF_KEY)
printf("%-*.*s %-*.*s %-6.6s %6.6s %8.8s %6.6s %s\n",
WID_DST(af), WID_DST(af), "Destination",
@@ -240,7 +238,7 @@ get_rtaddrs(int addrs, struct sockaddr *sa, struct sockaddr **rti_info)
* Print a routing table entry.
*/
void
-p_rtentry(struct rt_msghdr *rtm, int Aflag)
+p_rtentry(struct rt_msghdr *rtm)
{
static int old_af = -1;
struct sockaddr *sa = (struct sockaddr *)(rtm + 1);
@@ -253,7 +251,7 @@ p_rtentry(struct rt_msghdr *rtm, int Aflag)
if (old_af != sa->sa_family) {
old_af = sa->sa_family;
pr_family(sa->sa_family);
- pr_rthdr(sa->sa_family, Aflag);
+ pr_rthdr(sa->sa_family);
}
get_rtaddrs(rtm->rtm_addrs, sa, rti_info);
@@ -290,7 +288,7 @@ p_pfkentry(struct sadb_msg *msg)
void *headers[SADB_EXT_MAX + 1];
if (!old) {
- pr_rthdr(PF_KEY, 0);
+ pr_rthdr(PF_KEY);
old++;
}
diff --git a/sbin/route/show.h b/sbin/route/show.h
index 7b8d3f26f21..dff6b350b6d 100644
--- a/sbin/route/show.h
+++ b/sbin/route/show.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: show.h,v 1.4 2005/03/30 05:40:55 henning Exp $ */
+/* $OpenBSD: show.h,v 1.5 2006/05/27 18:26:45 claudio Exp $ */
/*
* Copyright (c) 2004 Claudio Jeker <claudio@openbsd.org>
@@ -19,7 +19,7 @@
#ifndef __SHOW_H__
#define __SHOW_H__
-void p_rttables(int, int);
+void p_rttables(int);
char *routename(struct sockaddr *);
char *netname(struct sockaddr *, struct sockaddr *);