mirror of
https://github.com/NetworkConfiguration/dhcpcd.git
synced 2026-01-26 14:13:26 +00:00
ND Route Information Option prefix is optional
As the length could be zero and is RFC compliant. Fixes #527.
This commit is contained in:
parent
4b7065a78f
commit
6dcb1569fc
@ -74,7 +74,7 @@ embed byte length
|
||||
# bits 4 and 5 are route preference
|
||||
embed bitflags=00011 prf
|
||||
embed uint32 lifetime
|
||||
embed truncated ip6address prefix
|
||||
embed optional truncated ip6address prefix
|
||||
|
||||
# ND6 options, RFC6101
|
||||
definend 25 index embed rdnss
|
||||
|
||||
@ -417,7 +417,7 @@ embed byte length
|
||||
# bits 4 and 5 are route preference
|
||||
embed bitflags=00011 prf
|
||||
embed uint32 lifetime
|
||||
embed truncated ip6address prefix
|
||||
embed optional truncated ip6address prefix
|
||||
|
||||
# ND6 options, RFC6101
|
||||
definend 25 index embed rdnss
|
||||
|
||||
@ -2093,7 +2093,7 @@ err_sla:
|
||||
t |= OT_RESERVED;
|
||||
}
|
||||
}
|
||||
if (t & OT_TRUNCATED && t != (OT_ADDRIPV6 | OT_TRUNCATED)) {
|
||||
if (t & OT_TRUNCATED && !(t & OT_ADDRIPV6)) {
|
||||
logerrx("truncated only works for ip6address");
|
||||
return -1;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user