Use ofputil_uninit_group_mod() instead of
ofputil_bucket_list_destroy(). Currently these have the same effect,
but this will change in a following patch.
Signed-off-by: Jarno Rajahalme <jarno@ovn.org>
Acked-by: Ben Pfaff <blp@ovn.org>
- ofputil_bucket_list_destroy(&gm->buckets);
+ ofputil_uninit_group_mod(gm);
free(string);
if (error) {
free(string);
if (error) {
- ofputil_bucket_list_destroy(&gm->buckets);
+ ofputil_uninit_group_mod(gm);
size_t i;
for (i = 0; i < *n_gms; i++) {
size_t i;
for (i = 0; i < *n_gms; i++) {
- ofputil_bucket_list_destroy(&(*gms)[i].buckets);
+ ofputil_uninit_group_mod(&(*gms)[i]);
}
free(*gms);
*gms = NULL;
}
free(*gms);
*gms = NULL;
ds_put_char(s, ' ');
ofp_print_group(s, gd.group_id, gd.type, &gd.buckets, &gd.props,
oh->version, false);
ds_put_char(s, ' ');
ofp_print_group(s, gd.group_id, gd.type, &gd.buckets, &gd.props,
oh->version, false);
- ofputil_bucket_list_destroy(&gd.buckets);
+ ofputil_uninit_group_desc(&gd);
return;
}
ofp_print_group_mod__(s, oh->version, &gm);
return;
}
ofp_print_group_mod__(s, oh->version, &gm);
- ofputil_bucket_list_destroy(&gm.buckets);
+ ofputil_uninit_group_mod(&gm);
ofmonitor_flush(ofproto->connmgr);
ovs_mutex_unlock(&ofproto_mutex);
ofmonitor_flush(ofproto->connmgr);
ovs_mutex_unlock(&ofproto_mutex);
- ofputil_bucket_list_destroy(&ogm.gm.buckets);
+ ofputil_uninit_group_mod(&ogm.gm);
gm.command_bucket_id = OFPG15_BUCKET_ALL;
ovs_list_init(&gm.buckets);
queue_msg(encode_group_mod(&gm));
gm.command_bucket_id = OFPG15_BUCKET_ALL;
ovs_list_init(&gm.buckets);
queue_msg(encode_group_mod(&gm));
- ofputil_bucket_list_destroy(&gm.buckets);
+ ofputil_uninit_group_mod(&gm);
/* Clear installed_flows, to match the state of the switch. */
ovn_flow_table_clear();
/* Clear installed_flows, to match the state of the switch. */
ovn_flow_table_clear();
free(error);
}
ds_destroy(&group_string);
free(error);
}
ds_destroy(&group_string);
- ofputil_bucket_list_destroy(&gm.buckets);
+ ofputil_uninit_group_mod(&gm);
free(error);
}
ds_destroy(&group_string);
free(error);
}
ds_destroy(&group_string);
- ofputil_bucket_list_destroy(&gm.buckets);
+ ofputil_uninit_group_mod(&gm);
/* Remove 'installed' from 'group_table->existing_groups' */
hmap_remove(&group_table->existing_groups, &installed->hmap_node);
/* Remove 'installed' from 'group_table->existing_groups' */
hmap_remove(&group_table->existing_groups, &installed->hmap_node);
if (request) {
transact_noreply(vconn, request);
}
if (request) {
transact_noreply(vconn, request);
}
+ ofputil_uninit_group_mod(gm);
enum ofputil_protocol usable_protocols;
size_t n_gms = 0;
char *error;
enum ofputil_protocol usable_protocols;
size_t n_gms = 0;
char *error;
error = parse_ofp_group_mod_file(argv[2], command, &gms, &n_gms,
&usable_protocols);
error = parse_ofp_group_mod_file(argv[2], command, &gms, &n_gms,
&usable_protocols);
ovs_fatal(0, "%s", error);
}
ofctl_group_mod__(argv[1], gms, n_gms, usable_protocols);
ovs_fatal(0, "%s", error);
}
ofctl_group_mod__(argv[1], gms, n_gms, usable_protocols);
- for (i = 0; i < n_gms; i++) {
- ofputil_bucket_list_destroy(&gms[i].buckets);
- }
ovs_fatal(0, "%s", error);
}
ofctl_group_mod__(argv[1], &gm, 1, usable_protocols);
ovs_fatal(0, "%s", error);
}
ofctl_group_mod__(argv[1], &gm, 1, usable_protocols);
- ofputil_bucket_list_destroy(&gm.buckets);