diff options
author | Neale Ranns <nranns@cisco.com> | 2017-08-09 05:43:35 -0700 |
---|---|---|
committer | Neale Ranns <nranns@cisco.com> | 2017-08-10 08:53:06 +0000 |
commit | 9104a40aeb655982ed4eb0daf048a51902428813 (patch) | |
tree | 1284c8228f98a265ffb00820801d49d408f4c4bd | |
parent | 66c0adf1ea73f1347ab5e3b929fa378a597aeb15 (diff) |
MPLS tunnel - multiple labels on the CLI - fix cut and paste robot errors
Change-Id: I675af62d9c0c9cf2e340bf19e902695861d4e4b5
Signed-off-by: Neale Ranns <nranns@cisco.com>
-rw-r--r-- | src/vnet/mpls/mpls_tunnel.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/src/vnet/mpls/mpls_tunnel.c b/src/vnet/mpls/mpls_tunnel.c index 5211c926..2d5521f4 100644 --- a/src/vnet/mpls/mpls_tunnel.c +++ b/src/vnet/mpls/mpls_tunnel.c @@ -802,20 +802,11 @@ vnet_create_mpls_tunnel_command_fn (vlib_main_t * vm, is_del = 0; else if (unformat (line_input, "out-labels")) { - if (vec_len (rpaths) == 0) - { - error = clib_error_return (0, "Paths then labels"); - goto done; - } - else + while (unformat (line_input, "%U", + unformat_mpls_unicast_label, + &out_label)) { - while (unformat (line_input, "%U", - unformat_mpls_unicast_label, - &out_label)) - { - vec_add1 (rpaths[vec_len (rpaths) - 1].frp_label_stack, - out_label); - } + vec_add1 (rpath.frp_label_stack, out_label); } } else if (unformat (line_input, "via %U %U", |