]> git.ipfire.org Git - thirdparty/iproute2.git/commit
ip6/tunnel: Unify flowlabel printing
authorSerhey Popovych <serhe.popovych@gmail.com>
Wed, 10 Jan 2018 15:53:12 +0000 (17:53 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Wed, 10 Jan 2018 16:06:12 +0000 (08:06 -0800)
commita0fd0c3a30c82f4be486190a96fe7dd9428fa5ba
tree0f70d3fb08d52e572d76a2838abdd5033bda5128
parent090524f8995a56ed45734376a9eab6dc7803aa04
ip6/tunnel: Unify flowlabel printing

Use @s2 buffer to store string representation of
flowlabel and get rid of extra SPRINT_BUF(): no
need to preserve @s2 contents for later.

Use print_string(PRINT_ANY, ...) with prepared by
snprintf() string for both PRINT_JSON and PRINT_FP
cases.

Omit flowlabel from output if no flowinfo attribute
is given and IP6_TNL_F_USE_ORIG_FLOWLABEL isn't set.

Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
ip/link_gre6.c
ip/link_ip6tnl.c