Mercurial > hg > dhcpcd
changeset 2204:cc598e8e72b0 draft
Tweak unicast a little
| author | Roy Marples <roy@marples.name> |
|---|---|
| date | Fri, 13 Dec 2013 14:54:14 +0000 |
| parents | a402f9e802a6 |
| children | 2496e7e94229 |
| files | dhcp6.c |
| diffstat | 1 files changed, 4 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/dhcp6.c Fri Dec 13 09:35:35 2013 +0000 +++ b/dhcp6.c Fri Dec 13 14:54:14 2013 +0000 @@ -716,12 +716,10 @@ /* We need to ensure we have sufficient scope to unicast the address */ /* XXX FIXME: We should check any added addresses we have like from * a Router Advertisement */ - if (!IN6_IS_ADDR_UNSPECIFIED(&state->unicast) && - state->state == DH6S_REQUEST && - (!IN6_IS_ADDR_LINKLOCAL(&state->unicast) || !ipv6_linklocal(ifp))) - state->unicast = in6addr_any; - - if (IN6_IS_ADDR_UNSPECIFIED(&state->unicast)) { + if (IN6_IS_ADDR_UNSPECIFIED(&state->unicast) || + (state->state == DH6S_REQUEST && + (!IN6_IS_ADDR_LINKLOCAL(&state->unicast) || !ipv6_linklocal(ifp)))) + { to.sin6_addr = in6addr_linklocal_alldhcp; broad_uni = "broadcasting"; } else {
