Fix wrong interger type when unformating value in VAT
[vpp.git] / vpp-api-test / vat / api_format.c
index a4fbf0d..504c3b4 100644 (file)
@@ -5743,7 +5743,7 @@ static int api_sw_interface_ip6nd_ra_config (vat_main_t * vam)
     f64 timeout;
     u32 sw_if_index;
     u8 sw_if_index_set = 0;
-    u8 surpress = 0;
+    u8 suppress = 0;
     u8 managed = 0;
     u8 other = 0;
     u8 ll_option = 0;
@@ -5774,8 +5774,8 @@ static int api_sw_interface_ip6nd_ra_config (vat_main_t * vam)
             ;
         else if (unformat (i, "interval %d", &initial_interval))
             ;
-       else if (unformat (i, "surpress"))
-           surpress = 1;
+       else if (unformat (i, "suppress") || unformat (i, "surpress"))
+           suppress = 1;
        else if (unformat (i, "managed"))
            managed = 1;
        else if (unformat (i, "other"))
@@ -5810,7 +5810,7 @@ static int api_sw_interface_ip6nd_ra_config (vat_main_t * vam)
     mp->lifetime = ntohl(lifetime);
     mp->initial_count = ntohl(initial_count);
     mp->initial_interval = ntohl(initial_interval);
-    mp->surpress = surpress;
+    mp->suppress = suppress;
     mp->managed = managed;
     mp->other = other;
     mp->ll_option = ll_option;
@@ -10013,9 +10013,9 @@ api_lisp_add_del_locator(vat_main_t * vam)
     u32 sw_if_index = ~0;
     u8  sw_if_index_set = 0;
     u8  sw_if_index_if_name_set = 0;
-    u8  priority = ~0;
+    u32  priority = ~0;
     u8  priority_set = 0;
-    u8  weight = ~0;
+    u32  weight = ~0;
     u8  weight_set = 0;
     u8  is_add = 1;
     u8  *locator_set_name = NULL;
@@ -10112,7 +10112,7 @@ api_lisp_add_del_local_eid(vat_main_t * vam)
     ip4_address_t eidv4;
     ip6_address_t eidv6;
     u8 mac[6] = {0};
-    u8 tmp_eid_lenght = ~0;
+    u32 tmp_eid_lenght = ~0;
     u8 eid_lenght = ~0;
     u8 *locator_set_name = NULL;
     u8 locator_set_name_set = 0;
@@ -10221,7 +10221,7 @@ api_lisp_gpe_add_del_fwd_entry(vat_main_t * vam)
     u8 eidv6_set = 0, slocv6_set = 0, dlocv6_set = 0;
     ip4_address_t eidv4, slocv4, dlocv4;
     ip6_address_t eidv6, slocv6, dlocv6;
-    u8 tmp_eid_lenght = ~0;
+    u32 tmp_eid_lenght = ~0;
     u8 eid_lenght = ~0;
 
     /* Parse args required to build the message */
@@ -11982,7 +11982,7 @@ _(sw_interface_ip6nd_ra_prefix,                                         \
   "[nolink] [isno]")                                                    \
 _(sw_interface_ip6nd_ra_config,                                         \
   "<intfc> | sw_if_index <id> [maxint <n>] [minint <n>]\n"              \
-  "[life <n>] [count <n>] [interval <n>] [surpress]\n"                  \
+  "[life <n>] [count <n>] [interval <n>] [suppress]\n"                  \
   "[managed] [other] [ll] [send] [cease] [isno] [def]")                 \
 _(set_arp_neighbor_limit, "arp_nbr_limit <n> [ipv6]")                   \
 _(l2_patch_add_del,                                                     \