2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

ofp-util: Fix group desc request encoding.

Signed-off-by: Minoru TAKAHASHI <takahashi.minoru7@gmail.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
Minoru TAKAHASHI
2015-07-24 13:31:58 +09:00
committed by Ben Pfaff
parent 1bc331dba7
commit d4d3f33e55
3 changed files with 8 additions and 7 deletions

View File

@@ -7257,7 +7257,6 @@ ofputil_encode_group_desc_request(enum ofp_version ofp_version,
uint32_t group_id)
{
struct ofpbuf *request;
ovs_be32 gid;
switch (ofp_version) {
case OFP10_VERSION:
@@ -7270,12 +7269,14 @@ ofputil_encode_group_desc_request(enum ofp_version ofp_version,
request = ofpraw_alloc(OFPRAW_OFPST11_GROUP_DESC_REQUEST,
ofp_version, 0);
break;
case OFP15_VERSION:
case OFP15_VERSION:{
struct ofp15_group_desc_request *req;
request = ofpraw_alloc(OFPRAW_OFPST15_GROUP_DESC_REQUEST,
ofp_version, 0);
gid = htonl(group_id);
ofpbuf_put(request, &gid, sizeof gid);
req = ofpbuf_put_zeros(request, sizeof *req);
req->group_id = htonl(group_id);
break;
}
default:
OVS_NOT_REACHED();
}