diff options
author | 2013-11-08 09:18:27 +0000 | |
---|---|---|
committer | 2013-11-08 09:18:27 +0000 | |
commit | 5ce7c03d9488fc1eaeeabdef9b529a06eb5e2b9e (patch) | |
tree | 407ddbd3be33c3bcb7640b677c29d29e0fb1c9f3 | |
parent | sync (diff) | |
download | wireguard-openbsd-5ce7c03d9488fc1eaeeabdef9b529a06eb5e2b9e.tar.xz wireguard-openbsd-5ce7c03d9488fc1eaeeabdef9b529a06eb5e2b9e.zip |
To make sure detach hooks are executed in reverse order they were added,
they must be appended to the head of the list. It doesn't really matter
right now since most of our pseudo drivers use their own custom detach
procedure, but teach vlan(4) to do the right thing since more conversion
are coming.
ok deraadt@
-rw-r--r-- | sys/net/if_vlan.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/net/if_vlan.c b/sys/net/if_vlan.c index 86b25ffdc6f..ae2af7dc60c 100644 --- a/sys/net/if_vlan.c +++ b/sys/net/if_vlan.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vlan.c,v 1.100 2013/11/07 11:19:32 mpi Exp $ */ +/* $OpenBSD: if_vlan.c,v 1.101 2013/11/08 09:18:27 mpi Exp $ */ /* * Copyright 1998 Massachusetts Institute of Technology @@ -446,7 +446,7 @@ vlan_config(struct ifvlan *ifv, struct ifnet *p, u_int16_t tag) vlan_vlandev_state, ifv); /* Register callback if parent wants to unregister */ - ifv->dh_cookie = hook_establish(p->if_detachhooks, 1, + ifv->dh_cookie = hook_establish(p->if_detachhooks, 0, vlan_ifdetach, ifv); vlan_vlandev_state(ifv); |