]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
network: drop redundant condition
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 13 Feb 2022 10:54:09 +0000 (19:54 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 13 Feb 2022 11:01:29 +0000 (20:01 +0900)
The function `link_drop_foreign_addresses()` is only called in
`link_drop_foreign_config()`, and the same condition is located in the
caller.

src/network/networkd-address.c

index b083b632b124c5a94dc2ab17c4f1de305fc1deaa..35142093ddbc3e26fe792f7dd4dd950a48f29229 100644 (file)
@@ -848,10 +848,6 @@ int link_drop_foreign_addresses(Link *link) {
         assert(link);
         assert(link->network);
 
-        /* Keep all addresses when KeepConfiguration=yes. */
-        if (link->network->keep_configuration == KEEP_CONFIGURATION_YES)
-                return 0;
-
         /* First, mark all addresses. */
         SET_FOREACH(address, link->addresses) {
                 /* We consider IPv6LL addresses to be managed by the kernel, or dropped in link_drop_ipv6ll_addresses() */