Combine several checks in nd6_prefix_offlink() into one.
MFC after: 1 week
This commit is contained in:
parent
9a99954958
commit
7b0e84b7c8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=306826
@ -1825,17 +1825,12 @@ nd6_prefix_offlink(struct nd_prefix *pr)
|
||||
* interface.
|
||||
*/
|
||||
LIST_FOREACH(opr, &V_nd_prefix, ndpr_entry) {
|
||||
if (opr == pr)
|
||||
continue;
|
||||
|
||||
if ((opr->ndpr_stateflags & NDPRF_ONLINK) != 0)
|
||||
continue;
|
||||
|
||||
/*
|
||||
* KAME specific: detached prefixes should not be
|
||||
* on-link.
|
||||
*/
|
||||
if ((opr->ndpr_stateflags & NDPRF_DETACHED) != 0)
|
||||
if (opr == pr || (opr->ndpr_stateflags &
|
||||
(NDPRF_ONLINK | NDPRF_DETACHED)) != 0)
|
||||
continue;
|
||||
|
||||
if (opr->ndpr_plen == pr->ndpr_plen &&
|
||||
|
Loading…
Reference in New Issue
Block a user