X Tutup
Skip to content

Commit 9e86dba

Browse files
committed
network: drop IPv6LL addresses manually configured in .network file
1 parent 97b6ed3 commit 9e86dba

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/network/networkd-address.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -895,8 +895,11 @@ int link_drop_addresses(Link *link) {
895895
if (!address_exists(address))
896896
continue;
897897

898-
/* We consider IPv6LL addresses to be managed by the kernel, or dropped in link_drop_ipv6ll_addresses() */
899-
if (address->family == AF_INET6 && in6_addr_is_link_local(&address->in_addr.in6))
898+
/* Do not drop IPv6LL addresses assigned by the kernel here. They will be dropped in
899+
* link_drop_ipv6ll_addresses() if IPv6LL addressing is disabled. */
900+
if (address->source == NETWORK_CONFIG_SOURCE_FOREIGN &&
901+
address->family == AF_INET6 &&
902+
in6_addr_is_link_local(&address->in_addr.in6))
900903
continue;
901904

902905
k = address_remove(address);

0 commit comments

Comments
 (0)
X Tutup