diff options
author | ckishimo <carles.kishimoto@gmail.com> | 2021-02-23 15:12:11 +0100 |
---|---|---|
committer | ckishimo <carles.kishimoto@gmail.com> | 2021-02-23 15:39:25 +0100 |
commit | 66721aaee7990e505db78bfe077c2df6312dc27a (patch) | |
tree | 2d8abf8178215433b5dfd749b0654392bae0aa0b /ospf6d/ospf6_proto.c | |
parent | Merge pull request #8130 from ton31337/feature/document_systemtap_usdt (diff) | |
download | frr-66721aaee7990e505db78bfe077c2df6312dc27a.tar.xz frr-66721aaee7990e505db78bfe077c2df6312dc27a.zip |
ospf6d: print prefix options for lsa type 3 and 5
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Diffstat (limited to 'ospf6d/ospf6_proto.c')
-rw-r--r-- | ospf6d/ospf6_proto.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/ospf6d/ospf6_proto.c b/ospf6d/ospf6_proto.c index 864974c9a..a746037ec 100644 --- a/ospf6d/ospf6_proto.c +++ b/ospf6d/ospf6_proto.c @@ -60,7 +60,21 @@ void ospf6_prefix_apply_mask(struct ospf6_prefix *op) void ospf6_prefix_options_printbuf(uint8_t prefix_options, char *buf, int size) { - snprintf(buf, size, "xxx"); + const char *p, *mc, *la, *nu; + + p = (CHECK_FLAG(prefix_options, OSPF6_PREFIX_OPTION_P) + ? "P" + : "--"); + mc = (CHECK_FLAG(prefix_options, OSPF6_PREFIX_OPTION_MC) + ? "MC" + : "--"); + la = (CHECK_FLAG(prefix_options, OSPF6_PREFIX_OPTION_LA) + ? "LA" + : "--"); + nu = (CHECK_FLAG(prefix_options, OSPF6_PREFIX_OPTION_NU) + ? "NU" + : "--"); + snprintf(buf, size, "%s|%s|%s|%s", p, mc, la, nu); } void ospf6_capability_printbuf(char capability, char *buf, int size) |