git: netstat: Make netstat -rn more resilient to having the routing table changing

Sepherosa Ziehau sephe at crater.dragonflybsd.org
Mon Nov 19 01:51:03 PST 2012


commit 0e23ab10e5db9a505c79ad0f5972c2740ddd3341
Author: Sepherosa Ziehau <sephe at dragonflybsd.org>
Date:   Mon Nov 19 17:51:24 2012 +0800

    netstat: Make netstat -rn more resilient to having the routing table changing
    
    Obtained-from: FreeBSD 176289 by jhb
      "Make netstat -rn more resilient to having the routing table change out from
       under it while running.  Note that this is still not perfect:
       - Try to do something intelligent if kvm_read() fails to read a routing
         table structure such as an rtentry, radix_node, or ifnet.
       - Don't follow left and right node pointers in radix_nodes unless
         RNF_ACTIVE is set in rn_flags.  This avoids walking through freed
         radix_nodes."

Summary of changes:
 usr.bin/netstat/route.c |   62 ++++++++++++++++++++++++++++++++--------------
 1 files changed, 43 insertions(+), 19 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/0e23ab10e5db9a505c79ad0f5972c2740ddd3341


-- 
DragonFly BSD source repository



More information about the Commits mailing list