vat: fix increment_address(...)
vl_api_address_t uses a packed enum for the address family, compare
a->af directly with ADDRESS_IP4 / ADDRESS_IP6 instead of running a->af
through clib_host_to_net_u32(...) before compare.
Indirectly fixes api_ip_route_add_del(...) w/ count > 1.
Type: fix
@@ -766,9 +766,9 @@ increment_v6_address (vl_api_ip6_address_t * i)
static void
increment_address (vl_api_address_t * a)
{
- if (clib_net_to_host_u32 (a->af) == ADDRESS_IP4)
+ if (a->af == ADDRESS_IP4)
increment_v4_address (&a->un.ip4);
- else if (clib_net_to_host_u32 (a->af) == ADDRESS_IP6)
+ else if (a->af == ADDRESS_IP6)
increment_v6_address (&a->un.ip6);
}
