aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/lb/api.c
diff options
context:
space:
mode:
authorVratko Polak <vrpolak@cisco.com>2019-09-20 18:23:58 +0200
committerAndrew Yourtchenko <ayourtch@gmail.com>2019-09-26 07:05:54 +0000
commit6eb009ac023799e4ee1b75d759d726622c39de78 (patch)
tree97e83ef994453f7e5d4b737191c7fc6f5784349e /src/plugins/lb/api.c
parentdf40cb5b5084f59ad8699f167192221955433a64 (diff)
lb: vl_api_lb_conf_t_handler has to ntohl
As requested in review, this is a minimal edit. Refactor comes as a separate Change. Type: fix Change-Id: Ie3bdfc3cfde4bfee56848217133ca5f6bbccaeef Signed-off-by: Vratko Polak <vrpolak@cisco.com>
Diffstat (limited to 'src/plugins/lb/api.c')
-rw-r--r--src/plugins/lb/api.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/lb/api.c b/src/plugins/lb/api.c
index 53541799f49..0543720e4e5 100644
--- a/src/plugins/lb/api.c
+++ b/src/plugins/lb/api.c
@@ -78,16 +78,16 @@ vl_api_lb_conf_t_handler
int rv = 0;
if (mp->sticky_buckets_per_core == ~0) {
- mp->sticky_buckets_per_core = lbm->per_cpu_sticky_buckets;
+ mp->sticky_buckets_per_core = htonl(lbm->per_cpu_sticky_buckets);
}
if (mp->flow_timeout == ~0) {
- mp->flow_timeout = lbm->flow_timeout;
+ mp->flow_timeout = htonl(lbm->flow_timeout);
}
rv = lb_conf((ip4_address_t *)&mp->ip4_src_address,
(ip6_address_t *)&mp->ip6_src_address,
- mp->sticky_buckets_per_core,
- mp->flow_timeout);
+ ntohl(mp->sticky_buckets_per_core),
+ ntohl(mp->flow_timeout));
REPLY_MACRO (VL_API_LB_CONF_REPLY);
}