diff --git a/src/shared/dns-configuration.c b/src/shared/dns-configuration.c index 03c4f3e2f1..e79ecdd24f 100644 --- a/src/shared/dns-configuration.c +++ b/src/shared/dns-configuration.c @@ -157,6 +157,7 @@ DNSConfiguration* dns_configuration_free(DNSConfiguration *c) { dns_server_free(c->current_dns_server); set_free(c->dns_servers); set_free(c->search_domains); + set_free(c->fallback_dns_servers); free(c->ifname); free(c->dnssec_mode_str); free(c->dns_over_tls_mode_str); @@ -186,10 +187,10 @@ static int dispatch_dns_configuration(const char *name, sd_json_variant *variant { "dnsOverTLS", SD_JSON_VARIANT_STRING, sd_json_dispatch_string, offsetof(DNSConfiguration, dns_over_tls_mode_str), 0 }, { "llmnr", SD_JSON_VARIANT_STRING, sd_json_dispatch_string, offsetof(DNSConfiguration, llmnr_mode_str), 0 }, { "mDNS", SD_JSON_VARIANT_STRING, sd_json_dispatch_string, offsetof(DNSConfiguration, mdns_mode_str), 0 }, + { "fallbackServers", SD_JSON_VARIANT_ARRAY, dispatch_dns_server_array, offsetof(DNSConfiguration, fallback_dns_servers), 0 }, /* The remaining fields are currently unused by wait-online. */ { "delegate", _SD_JSON_VARIANT_TYPE_INVALID, NULL, 0, 0 }, - { "fallbackServers", _SD_JSON_VARIANT_TYPE_INVALID, NULL, 0, 0 }, { "negativeTrustAnchors", _SD_JSON_VARIANT_TYPE_INVALID, NULL, 0, 0 }, { "resolvConfMode", _SD_JSON_VARIANT_TYPE_INVALID, NULL, 0, 0 }, { "scopes", _SD_JSON_VARIANT_TYPE_INVALID, NULL, 0, 0 }, diff --git a/src/shared/dns-configuration.h b/src/shared/dns-configuration.h index 9e2addd0a0..8372fa86aa 100644 --- a/src/shared/dns-configuration.h +++ b/src/shared/dns-configuration.h @@ -33,6 +33,7 @@ typedef struct DNSConfiguration { DNSServer *current_dns_server; Set *dns_servers; Set *search_domains; + Set *fallback_dns_servers; char *dnssec_mode_str; char *dns_over_tls_mode_str; char *llmnr_mode_str;