mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-13 00:20:17 +01:00
dns: sd-resolved: fix hash table initialization
The hash table was not initialized if there was no D-Bus connection at the time of object creation. Fixes:f70ee67058('dns: sd-resolved: reset interface configuration on deactivation') https://bugzilla.redhat.com/show_bug.cgi?id=1894839 (cherry picked from commitd6457902d1) (cherry picked from commitcd58512ba3) (cherry picked from commit8c7049b4f0)
This commit is contained in:
parent
418dd27781
commit
c5682f736f
1 changed files with 1 additions and 2 deletions
|
|
@ -521,6 +521,7 @@ nm_dns_systemd_resolved_init (NMDnsSystemdResolved *self)
|
|||
NMDnsSystemdResolvedPrivate *priv = NM_DNS_SYSTEMD_RESOLVED_GET_PRIVATE (self);
|
||||
|
||||
c_list_init (&priv->request_queue_lst_head);
|
||||
priv->dirty_interfaces = g_hash_table_new (nm_direct_hash, NULL);
|
||||
|
||||
priv->dbus_connection = nm_g_object_ref (NM_MAIN_DBUS_CONNECTION_GET);
|
||||
if (!priv->dbus_connection) {
|
||||
|
|
@ -540,8 +541,6 @@ nm_dns_systemd_resolved_init (NMDnsSystemdResolved *self)
|
|||
priv->cancellable,
|
||||
get_name_owner_cb,
|
||||
self);
|
||||
|
||||
priv->dirty_interfaces = g_hash_table_new (nm_direct_hash, NULL);
|
||||
}
|
||||
|
||||
NMDnsPlugin *
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue