Subject: Re: netstat(1) broken for some time now
To: Rui Paulo <rpaulo@fnop.net>
From: Christos Zoulas <christos@zoulas.com>
List: current-users
Date: 09/14/2006 18:58:39
On Sep 14, 10:24pm, rpaulo@fnop.net (Rui Paulo) wrote:
-- Subject: Re: netstat(1) broken for some time now

| 
| On Sep 14, 2006, at 9:46 PM, Christos Zoulas wrote:
| 
| > I just fixed that.
| 
| I'm still in the sysctl school and I would like to have more comments  
| about adding the field to struct rt_msghdr/rt_metrics.
| 

I think it easier to:

Index: route.h
===================================================================
RCS file: /cvsroot/src/sys/net/route.h,v
retrieving revision 1.43
diff -u -u -r1.43 route.h
--- route.h	11 Dec 2005 12:24:52 -0000	1.43
+++ route.h	14 Sep 2006 22:58:21 -0000
@@ -72,6 +72,12 @@
 };
 
 /*
+ * Abuse those two fields for sysctl route info
+ */
+#define	rmx_refcount	rmx_locks
+#define	rmx_use		rmx_pksent
+
+/*
  * rmx_rtt and rmx_rttvar are stored as microseconds;
  * RTTTOPRHZ(rtt) converts to a value suitable for use
  * by a protocol slowtimo counter.