dns: fix handling of trust-ad option

Fixes: 5e47fb630b ('dns: add trust-ad DNS option only if all contributing settings agree')
This commit is contained in:
Beniamino Galvani 2020-04-21 10:47:18 +02:00
parent 938aca3fab
commit cb9a6f3b92

View file

@ -1197,7 +1197,7 @@ _collect_resolv_conf_data (NMDnsManager *self,
}
if (rc.has_trust_ad == NM_TERNARY_TRUE)
g_ptr_array_add (rc.options, NM_SETTING_DNS_OPTION_TRUST_AD);
g_ptr_array_add (rc.options, g_strdup (NM_SETTING_DNS_OPTION_TRUST_AD));
*out_searches = _ptrarray_to_strv (rc.searches);
*out_options = _ptrarray_to_strv (rc.options);