git: netinet: Improve local routes handling in in_addroute()

Aaron LI aly at crater.dragonflybsd.org
Fri Nov 13 21:51:12 PST 2026


commit e841b450c6168db6ebca8c0b501f45629c554a79
Author: Aaron LI <aly at aaronly.me>
Date:   Fri Nov 13 22:34:14 2026 +0800

    netinet: Improve local routes handling in in_addroute()
    
    * Extract the in_rtlocalize() helper function to improve the handling of
      local routes, including explicit loopback routes added by
      ifa_add_loopback_route().
    * Skip modifying IFA/IFP for the explicit loopback routes, and thus
      remove the pre-setting RTF_LOCAL from ifa_maintain_loopback_route().
    
    No functional changes.

Summary of changes:
 sys/net/if.c         |  7 +---
 sys/netinet/in_rmx.c | 94 +++++++++++++++++++++++++++++++++++++---------------
 2 files changed, 69 insertions(+), 32 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/e841b450c6168db6ebca8c0b501f45629c554a79


-- 
DragonFly BSD source repository


More information about the Commits mailing list