diff --git a/clients/common/nm-meta-setting-desc.c b/clients/common/nm-meta-setting-desc.c index 4d2ed10ead..b8c2320c21 100644 --- a/clients/common/nm-meta-setting-desc.c +++ b/clients/common/nm-meta-setting-desc.c @@ -6112,8 +6112,6 @@ static const NMMetaPropertyInfo *const property_infos_SRIOV[] = { .clear_all_fcn = OBJLIST_CLEAR_ALL_FCN (NMSettingSriov, nm_setting_sriov_clear_vfs), .obj_to_str_fcn = _objlist_obj_to_str_fcn_sriov_vfs, .set_fcn = _objlist_set_fcn_sriov_vfs, - /* FIXME: removing by index is ambigous and should maybe be prevented. */ - .remove_by_idx_fcn_u = OBJLIST_REMOVE_BY_IDX_FCN_U (NMSettingSriov, nm_setting_sriov_remove_vf), ), ), ), diff --git a/libnm-core/nm-utils.c b/libnm-core/nm-utils.c index 854bfec794..9f3b209ccf 100644 --- a/libnm-core/nm-utils.c +++ b/libnm-core/nm-utils.c @@ -2962,8 +2962,7 @@ nm_utils_sriov_vf_from_str (const char *str, GError **error) detail = strchr (str, ' '); if (detail) { - index_free = g_strndup (str, detail - str); - str = index_free; + str = nm_strndup_a (200, str, detail - str, &index_free); detail++; }