diff options
author | fenner <fenner@FreeBSD.org> | 1999-01-18 02:09:15 +0000 |
---|---|---|
committer | fenner <fenner@FreeBSD.org> | 1999-01-18 02:09:15 +0000 |
commit | f2b133839414cc17ec766c3e27f03fcee58a694d (patch) | |
tree | 1cce4e610387f23de9ad1aa5ce852b863857c61f /usr.bin/netstat/main.c | |
parent | c9e9dccbb7e008df4c1d1904f54554e6220f0616 (diff) | |
download | FreeBSD-src-f2b133839414cc17ec766c3e27f03fcee58a694d.zip FreeBSD-src-f2b133839414cc17ec766c3e27f03fcee58a694d.tar.gz |
Don't use ip_mrtproto to determine whether multicast routing is in
the kernel; this was left over from the earlier protocol-dependent
kernel multicast routing code.
Learn how to handle the malloc'd multicast routing table (instead of
expecting it to be in mbufs)
Diffstat (limited to 'usr.bin/netstat/main.c')
-rw-r--r-- | usr.bin/netstat/main.c | 26 |
1 files changed, 11 insertions, 15 deletions
diff --git a/usr.bin/netstat/main.c b/usr.bin/netstat/main.c index fd0c5bd..6680d07 100644 --- a/usr.bin/netstat/main.c +++ b/usr.bin/netstat/main.c @@ -42,7 +42,7 @@ char const copyright[] = static char sccsid[] = "@(#)main.c 8.4 (Berkeley) 3/1/94"; #endif static const char rcsid[] = - "$Id: main.c,v 1.21 1998/08/05 13:54:07 phk Exp $"; + "$Id: main.c,v 1.22 1998/08/08 08:13:04 phk Exp $"; #endif /* not lint */ #include <sys/param.h> @@ -105,23 +105,21 @@ static struct nlist nl[] = { { "_nfile" }, #define N_FILE 18 { "_file" }, -#define N_MRTPROTO 19 - { "_ip_mrtproto" }, -#define N_MRTSTAT 20 +#define N_MRTSTAT 19 { "_mrtstat" }, -#define N_MFCTABLE 21 +#define N_MFCTABLE 20 { "_mfctable" }, -#define N_VIFTABLE 22 +#define N_VIFTABLE 21 { "_viftable" }, -#define N_IPX 23 +#define N_IPX 22 { "_ipxpcb"}, -#define N_IPXSTAT 24 +#define N_IPXSTAT 23 { "_ipxstat"}, -#define N_SPXSTAT 25 +#define N_SPXSTAT 24 { "_spx_istat"}, -#define N_DDPSTAT 26 +#define N_DDPSTAT 25 { "_ddpstat"}, -#define N_DDPCB 27 +#define N_DDPCB 26 { "_ddpcb"}, { "" }, }; @@ -390,11 +388,9 @@ main(argc, argv) if (gflag) { kread(0, 0, 0); if (sflag) - mrt_stats(nl[N_MRTPROTO].n_value, - nl[N_MRTSTAT].n_value); + mrt_stats(nl[N_MRTSTAT].n_value); else - mroutepr(nl[N_MRTPROTO].n_value, - nl[N_MFCTABLE].n_value, + mroutepr(nl[N_MFCTABLE].n_value, nl[N_VIFTABLE].n_value); exit(0); } |