From 0d28f94a476068614c92801637eb40decea5d0e6 Mon Sep 17 00:00:00 2001 From: Ariadne Conill Date: Wed, 21 Oct 2020 08:09:21 -0600 Subject: [PATCH] interface: auto interfaces are always explicit --- libifupdown/interface-file.c | 3 +++ libifupdown/interface.c | 1 + 2 files changed, 4 insertions(+) diff --git a/libifupdown/interface-file.c b/libifupdown/interface-file.c index d2e88ac..6481be8 100644 --- a/libifupdown/interface-file.c +++ b/libifupdown/interface-file.c @@ -172,6 +172,9 @@ handle_auto(struct lif_interface_file_parse_state *state, char *token, char *buf if (!state->cur_iface->is_template) state->cur_iface->is_auto = true; + if (state->cur_iface->is_auto) + state->cur_iface->is_explicit = true; + return true; } diff --git a/libifupdown/interface.c b/libifupdown/interface.c index 532edba..7e96bcd 100644 --- a/libifupdown/interface.c +++ b/libifupdown/interface.c @@ -223,6 +223,7 @@ lif_interface_collection_init(struct lif_dict *collection) /* always enable loopback interface as part of a collection */ if_lo = lif_interface_collection_find(collection, "lo"); if_lo->is_auto = true; + if_lo->is_explicit = true; lif_interface_use_executor(if_lo, "loopback"); }