about summary refs log tree commit diff
path: root/src/core/settings/nm-settings-connection.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/settings/nm-settings-connection.c')
-rw-r--r--src/core/settings/nm-settings-connection.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/settings/nm-settings-connection.c b/src/core/settings/nm-settings-connection.c
index 36ef6acb..b423bf5b 100644
--- a/src/core/settings/nm-settings-connection.c
+++ b/src/core/settings/nm-settings-connection.c
@@ -2379,11 +2379,11 @@ _nm_settings_connection_register_kf_dbs(NMSettingsConnection *self,
                 priv->seen_bssids_hash = _seen_bssids_hash_new();
 
             entry = _seen_bssid_entry_new_stale_bin(&addr_bin);
+            c_list_link_tail(&priv->seen_bssids_lst_head, &entry->seen_bssids_lst);
             if (!g_hash_table_insert(priv->seen_bssids_hash, entry, entry)) {
                 /* duplicate detected! The @entry key was freed by g_hash_table_insert(). */
                 continue;
             }
-            c_list_link_tail(&priv->seen_bssids_lst_head, &entry->seen_bssids_lst);
             result_len++;
         }
         if (result_len > 0) {