diff options
author | Chris Luke <chrisy@flirble.org> | 2016-05-27 12:11:24 -0400 |
---|---|---|
committer | Chris Luke <chrisy@flirble.org> | 2016-05-27 12:13:51 -0400 |
commit | 404be66978ff77769953eb96c6db036574288697 (patch) | |
tree | dffad677fba93c475cbd65fad57bf14146510fb8 /vpp | |
parent | 68c69d896736e12730a7a9a55ec3d7dcbbd19e99 (diff) |
VPP-95 VXLAN add_del API intermittent failure
The VXLAN add_del API sometimes rejects calls with
VNET_API_ERROR_SAME_SRC_DST when the two parameters are obviously
different. This is because the API code is checking the "is_ip6" flag in
a not-yet initialized area of memory leading to random results.
Also fix help text for vxlan_add_del_tunnel in vat.
This does not change the API; it repairs intermittent failure.
Change-Id: I41863694f478c1f669078f82f69d8cca4841c989
Signed-off-by: Chris Luke <chrisy@flirble.org>
Diffstat (limited to 'vpp')
-rw-r--r-- | vpp/api/api.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vpp/api/api.c b/vpp/api/api.c index 8b801e5a..52d0b2d2 100644 --- a/vpp/api/api.c +++ b/vpp/api/api.c @@ -4330,8 +4330,8 @@ static void vl_api_vxlan_add_del_tunnel_t_handler encap_fib_index = p[0]; /* Check src & dst are different */ - if ((a->is_ip6 && memcmp(mp->src_address, mp->dst_address, 16) == 0) || - (!a->is_ip6 && memcmp(mp->src_address, mp->dst_address, 4) == 0)) { + if ((mp->is_ipv6 && memcmp(mp->src_address, mp->dst_address, 16) == 0) || + (!mp->is_ipv6 && memcmp(mp->src_address, mp->dst_address, 4) == 0)) { rv = VNET_API_ERROR_SAME_SRC_DST; goto out; } |