summaryrefslogtreecommitdiffhomepage
path: root/src/dhcpv6-ia.c
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2014-08-13 16:53:06 +0200
committerSteven Barth <steven@midlink.org>2014-08-13 16:53:06 +0200
commitf41da55f11f06361e23f11a87f179aa56565c106 (patch)
tree37d73d0d2e5dc3a56d042afd6cffedd800cf8c4e /src/dhcpv6-ia.c
parent479cd9f6a5b6c68285004aa30bacfb284121ac8e (diff)
PD: don't consider deprecated assigned prefixes when calculating avilable PD size
Diffstat (limited to 'src/dhcpv6-ia.c')
-rw-r--r--src/dhcpv6-ia.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dhcpv6-ia.c b/src/dhcpv6-ia.c
index 90dcaf5..2fef626 100644
--- a/src/dhcpv6-ia.c
+++ b/src/dhcpv6-ia.c
@@ -595,7 +595,7 @@ static void update(struct interface *iface)
int minprefix = -1;
for (int i = 0; i < len; ++i) {
- if (addr[i].prefix > minprefix)
+ if (addr[i].preferred > 0 && addr[i].prefix > minprefix)
minprefix = addr[i].prefix;
addr[i].addr.s6_addr32[3] = 0;