mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-29 19:40:12 +01:00
core: fix adding objects to NMIPConfig with @append_force
If the @append_force argument is set and the object is already in the list, it must be moved at the end. Fixes:22edeb5b69('core: track addresses for NMIP4Config/NMIP6Config via NMDedupMultiIndex') (cherry picked from commit8b121c7048) (cherry picked from commit52241748e8) (cherry picked from commitd6c3d9c9dc)
This commit is contained in:
parent
db1e24cc49
commit
11f355dc85
2 changed files with 4 additions and 4 deletions
|
|
@ -191,7 +191,9 @@ _nm_ip_config_add_obj (NMDedupMultiIndex *multi_idx,
|
|||
if (!nm_dedup_multi_index_add_full (multi_idx,
|
||||
&idx_type->parent,
|
||||
obj_new,
|
||||
NM_DEDUP_MULTI_IDX_MODE_APPEND,
|
||||
append_force
|
||||
? NM_DEDUP_MULTI_IDX_MODE_APPEND_FORCE
|
||||
: NM_DEDUP_MULTI_IDX_MODE_APPEND,
|
||||
NULL,
|
||||
entry_old ?: NM_DEDUP_MULTI_ENTRY_MISSING,
|
||||
NULL,
|
||||
|
|
|
|||
|
|
@ -113,9 +113,7 @@ test_replace (void)
|
|||
|
||||
g_assert (nm_ip4_config_replace (config2, config1, &relevant_changes));
|
||||
g_assert (relevant_changes);
|
||||
|
||||
/* FIXME: this currently fails due to a bug in replace() */
|
||||
g_assert (!nm_ip4_config_equal (config1, config2));
|
||||
g_assert (nm_ip4_config_equal (config1, config2));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue