summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2019-05-04 10:12:39 +0100
committerRoy Marples <roy@marples.name>2019-05-04 10:12:39 +0100
commit8c91009085b337e1edc54fdece26b7b5327fc8da (patch)
tree64e28bdf575d5209d96f0635ece27d959aac42a1
parent588aee42c5116573531ef83f5a3c28cd61126f38 (diff)
downloaddhcpcd-8c91009085b337e1edc54fdece26b7b5327fc8da.tar.xz
Remove old check
-rw-r--r--dhcp6.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/dhcp6.c b/dhcp6.c
index ed431be6..92ed9d0b 100644
--- a/dhcp6.c
+++ b/dhcp6.c
@@ -1992,22 +1992,14 @@ dhcp6_findpd(struct interface *ifp, const uint8_t *iaid,
}
/* Check option length matches prefix length. */
+ ol--;
if (((*op - a->prefix_len - 1) / NBBY) + 1 != ol) {
logger(ifp->ctx, LOG_ERR,
"%s: PD Exclude length mismatch", ifp->name);
continue;
}
-
a->prefix_exclude_len = *op++;
- ol--;
- if (((a->prefix_exclude_len - a->prefix_len - 1) / NBBY) + 1
- != ol)
- {
- logger(ifp->ctx, LOG_ERR,
- "%s: PD Exclude length mismatch", ifp->name);
- a->prefix_exclude_len = 0;
- continue;
- }
+
u8 = a->prefix_len % NBBY;
memcpy(&a->prefix_exclude, &a->prefix,
sizeof(a->prefix_exclude));