dns: don't use the global configuration to compute initial hash

If the initial hash includes the global configuration, every update
attempt will be skipped because the configuration never changes, and
resolv.conf will never be updated. Instead, use a NULL global
configuration to compute the hash and force an initial update.
This commit is contained in:
Beniamino Galvani 2016-05-10 08:54:25 +02:00
parent 8606060121
commit 16d5c8222b

View file

@ -1593,8 +1593,7 @@ nm_dns_manager_init (NMDnsManager *self)
priv->config = g_object_ref (nm_config_get ());
/* Set the initial hash */
compute_hash (self, nm_config_data_get_global_dns_config (nm_config_get_data (priv->config)),
NM_DNS_MANAGER_GET_PRIVATE (self)->hash);
compute_hash (self, NULL, NM_DNS_MANAGER_GET_PRIVATE (self)->hash);
g_signal_connect (G_OBJECT (priv->config),
NM_CONFIG_SIGNAL_CONFIG_CHANGED,