1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-01-11 05:17:44 +03:00

network: always enable IPv4 ACD for statically configured IPv4LL address

This commit is contained in:
Yu Watanabe 2021-06-16 06:54:47 +09:00
parent f4c48492fe
commit 1cf4ed142d

View File

@ -2115,6 +2115,13 @@ static int address_section_verify(Address *address) {
!FLAGS_SET(address->duplicate_address_detection, ADDRESS_FAMILY_IPV6))
address->flags |= IFA_F_NODAD;
if (address->family == AF_INET && in4_addr_is_link_local(&address->in_addr.in) &&
!FLAGS_SET(address->duplicate_address_detection, ADDRESS_FAMILY_IPV4)) {
log_debug("%s: An IPv4 link-local address is specified, enabling IPv4 Address Conflict Detection (ACD).",
address->section->filename);
address->duplicate_address_detection |= ADDRESS_FAMILY_IPV4;
}
return 0;
}