mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-10-06 16:21:50 +00:00
dhcp6: fix setting ifindex in nm_dhcp_utils_merge_new_dhcp6_lease()
nm_l3_config_data_new_clone() takes non-positive ifindex to use
the ifindex of the l3cd. But it also asserts that the ifindex
is not negative. Fix that assertion failure, by setting the ifindex
to zero.
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/issues/907
Fixes: 58287cbcc0
('core: rework IP configuration in NetworkManager using layer 3 configuration')
This commit is contained in:
parent
8384afa875
commit
5402a72179
|
@ -876,7 +876,7 @@ nm_dhcp_utils_merge_new_dhcp6_lease(const NML3ConfigData *l3cd_old,
|
|||
* addresses from the same transaction into a single configuration.
|
||||
**/
|
||||
|
||||
l3cd_merged = nm_l3_config_data_new_clone(l3cd_old, -1);
|
||||
l3cd_merged = nm_l3_config_data_new_clone(l3cd_old, 0);
|
||||
|
||||
nm_l3_config_data_iter_ip6_address_for_each (&iter, l3cd_new, &addr)
|
||||
nm_l3_config_data_add_address_6(l3cd_merged, addr);
|
||||
|
|
Loading…
Reference in a new issue