diff options
author | Neale Ranns <nranns@cisco.com> | 2019-11-12 17:16:47 +0000 |
---|---|---|
committer | Neale Ranns <nranns@cisco.com> | 2019-12-02 21:44:10 +0000 |
commit | d6d0edbf055ecabdec289727cef08becd9aca9b8 (patch) | |
tree | 222c75c3290d59fc3146197563353b6a74ebf8c5 /src/vat/api_format.c | |
parent | 77d760d708dcfe35aa805bd86381bc0bcb28f677 (diff) |
ip: IP address and prefix types (moved from LISP)
Type: refactor
Change-Id: I2c6b59013bfd21136a2955442c779685f951932b
Signed-off-by: Neale Ranns <nranns@cisco.com>
(cherry picked from commit ea93e48cf6e918937422638cb574964b88a146b6)
Diffstat (limited to 'src/vat/api_format.c')
-rw-r--r-- | src/vat/api_format.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vat/api_format.c b/src/vat/api_format.c index afbfde0fdfb..652fe0310c2 100644 --- a/src/vat/api_format.c +++ b/src/vat/api_format.c @@ -16597,13 +16597,13 @@ api_one_use_petr (vat_main_t * vam) if (unformat (input, "%U", unformat_ip4_address, &ip_addr_v4 (&ip))) { is_add = 1; - ip_addr_version (&ip) = IP4; + ip_addr_version (&ip) = AF_IP4; } else if (unformat (input, "%U", unformat_ip6_address, &ip_addr_v6 (&ip))) { is_add = 1; - ip_addr_version (&ip) = IP6; + ip_addr_version (&ip) = AF_IP6; } else { @@ -16617,7 +16617,7 @@ api_one_use_petr (vat_main_t * vam) mp->is_add = is_add; if (is_add) { - mp->is_ip4 = ip_addr_version (&ip) == IP4 ? 1 : 0; + mp->is_ip4 = ip_addr_version (&ip) == AF_IP4 ? 1 : 0; if (mp->is_ip4) clib_memcpy (mp->address, &ip, 4); else |