mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-18 10:35:55 +00:00
In in_purgemaddrs(), remove the inm being freed from the address list
before freeing it, rather than vice version, to avoid potential use after free. Reviewed by: bms
This commit is contained in:
parent
1c51765e41
commit
07cde5e92c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=191476
@ -1079,8 +1079,8 @@ in_purgemaddrs(struct ifnet *ifp)
|
||||
IF_ADDR_UNLOCK(ifp);
|
||||
|
||||
LIST_FOREACH_SAFE(inm, &purgeinms, inm_link, tinm) {
|
||||
inm_release_locked(inm);
|
||||
LIST_REMOVE(inm, inm_link);
|
||||
inm_release_locked(inm);
|
||||
}
|
||||
igmp_ifdetach(ifp);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user