]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
network: move ndisc_flush() to link_stop_engines()
authorYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 31 Jan 2022 10:09:30 +0000 (19:09 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Tue, 1 Feb 2022 02:30:37 +0000 (11:30 +0900)
As it is not related to any static configs.

src/network/networkd-link.c

index 3c5f3483bb19649c7dd690179fe77cd9a414234e..b68ee82c51f8e48eace68d07af208c2d965899e3 100644 (file)
@@ -430,6 +430,8 @@ int link_stop_engines(Link *link, bool may_keep_dhcp) {
         if (k < 0)
                 r = log_link_warning_errno(link, k, "Could not stop IPv6 Router Discovery: %m");
 
+        ndisc_flush(link);
+
         k = sd_radv_stop(link->radv);
         if (k < 0)
                 r = log_link_warning_errno(link, k, "Could not stop IPv6 Router Advertisement: %m");
@@ -1094,8 +1096,6 @@ static int link_drop_managed_config(Link *link) {
         if (k < 0 && r >= 0)
                 r = k;
 
-        ndisc_flush(link);
-
         return r;
 }