diff options
author | suz <suz@FreeBSD.org> | 2005-10-19 10:09:19 +0000 |
---|---|---|
committer | suz <suz@FreeBSD.org> | 2005-10-19 10:09:19 +0000 |
commit | 21f42e535fa6a4e118a72f5e8130dfff7456036a (patch) | |
tree | c362eb3bd52a94047053ab1b3c10c895d818bd69 /sys/netinet6/nd6_rtr.c | |
parent | 2043307751112834c9e2c0d1201a38aed095a6da (diff) | |
download | FreeBSD-src-21f42e535fa6a4e118a72f5e8130dfff7456036a.zip FreeBSD-src-21f42e535fa6a4e118a72f5e8130dfff7456036a.tar.gz |
sync with KAME in the following points:
- fixed typos
- improved some comment descriptions
- use NULL, instead of 0, to denote a NULL pointer
- avoid embedding a magic number in the code
- use nd6log() instead of log() to record NDP-specific logs
- nuked an unnecessay white space
Obtained from: KAME
MFC after: 1 day
Diffstat (limited to 'sys/netinet6/nd6_rtr.c')
-rw-r--r-- | sys/netinet6/nd6_rtr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/netinet6/nd6_rtr.c b/sys/netinet6/nd6_rtr.c index 3b53536..ccdbf29 100644 --- a/sys/netinet6/nd6_rtr.c +++ b/sys/netinet6/nd6_rtr.c @@ -1239,7 +1239,7 @@ pfxlist_onlink_check() break; } - if (pr) { + if (pr == NULL) { /* * There is at least one prefix that has a reachable router. * Detach prefixes which have no reachable advertising @@ -1300,7 +1300,7 @@ pfxlist_onlink_check() if ((e = nd6_prefix_offlink(pr)) != 0) { nd6log((LOG_ERR, "pfxlist_onlink_check: failed to " - "make %s/%d offlink, errno=%d\n", + "make %s/%d onlink, errno=%d\n", ip6_sprintf(&pr->ndpr_prefix.sin6_addr), pr->ndpr_plen, e)); } @@ -1382,8 +1382,8 @@ nd6_prefix_onlink(pr) if ((pr->ndpr_stateflags & NDPRF_ONLINK) != 0) { nd6log((LOG_ERR, "nd6_prefix_onlink: %s/%d is already on-link\n", - ip6_sprintf(&pr->ndpr_prefix.sin6_addr), pr->ndpr_plen); - return (EEXIST)); + ip6_sprintf(&pr->ndpr_prefix.sin6_addr), pr->ndpr_plen)); + return (EEXIST); } /* |