From 26591ffffd62c62796b1f65146648022d68e1279 Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Sun, 14 Nov 2021 15:46:47 +0900 Subject: [PATCH] resolve: do not clear DNS servers or friends on link which is not managed by networkd When networkd detects an unmanaged link, then the state is changed in the following order: pending -> initialized -> unmanaged The "initialized" state was added by bd08ce56156751d58584a44e766ef61340cdae2d. --- src/resolve/resolved-link.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resolve/resolved-link.c b/src/resolve/resolved-link.c index 18dc3d29e9c..dd219f297ce 100644 --- a/src/resolve/resolved-link.c +++ b/src/resolve/resolved-link.c @@ -565,7 +565,7 @@ static int link_is_managed(Link *l) { if (r < 0) return r; - return !STR_IN_SET(state, "pending", "unmanaged"); + return !STR_IN_SET(state, "pending", "initialized", "unmanaged"); } static void link_read_settings(Link *l) { -- 2.47.3