git: net: Announce IFAN_DEPARTURE message after route/address deletions
Aaron LI
aly at crater.dragonflybsd.org
Tue Dec 1 08:22:59 PST 2026
commit 21db3295516e53ed4dd8d324231b0bdb7e1309d2
Author: Aaron LI <aly at aaronly.me>
Date: Wed Dec 2 00:13:33 2026 +0800
net: Announce IFAN_DEPARTURE message after route/address deletions
The if_detach() function previously announced IFAN_DEPARTURE before
deleting the routes/addresses, so a userland program could receive a
RTM_DELADDR message after the interface had gone and thus cause
confusion. For example, bringing down a wg(4) interface would cause
dhcpcd(8) to emit the following warnings:
```
dhcpcd_handlelink: No such process
dhcpcd_handlelink: No such process
```
Fix this bug by moving the IFAN_DEPARTURE annoucement after the
route/address deletions.
This is a regression introduced in commit b4051e2552 (ifnet: Make ifnet
and ifindex2ifnet MPSAFE).
Summary of changes:
sys/net/if.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/21db3295516e53ed4dd8d324231b0bdb7e1309d2
--
DragonFly BSD source repository
More information about the Commits
mailing list