diff options
author | Philippe Guibert <philippe.guibert@6wind.com> | 2018-06-20 08:32:43 +0200 |
---|---|---|
committer | Philippe Guibert <philippe.guibert@6wind.com> | 2018-06-28 11:08:58 +0200 |
commit | 588ec356d094411f1330f6e0aab621f2ba5504b5 (patch) | |
tree | b79aed4f9bdf871602901e887a674c6e5bffaf8b /bgpd/bgp_flowspec_vty.c | |
parent | bgpd: support for enumerate pkt len (diff) | |
download | frr-588ec356d094411f1330f6e0aab621f2ba5504b5.tar.xz frr-588ec356d094411f1330f6e0aab621f2ba5504b5.zip |
bgpd: align fragment flowspec decoding with tcpflags
As fragment bitmask and tcpflags bitmask in flowspec protocol is encoded
in the same way, it is not necessary to differentiate those two fields.
Moreover, it overrides the initial fragment limit set to 1. It is now
possible to handle multiple framgent values.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'bgpd/bgp_flowspec_vty.c')
-rw-r--r-- | bgpd/bgp_flowspec_vty.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/bgpd/bgp_flowspec_vty.c b/bgpd/bgp_flowspec_vty.c index 6b0390ed0..90acd8fcb 100644 --- a/bgpd/bgp_flowspec_vty.c +++ b/bgpd/bgp_flowspec_vty.c @@ -173,7 +173,7 @@ void bgp_fs_nlri_get_string(unsigned char *nlri_content, size_t len, ptr += len_written; break; case FLOWSPEC_TCP_FLAGS: - ret = bgp_flowspec_tcpflags_decode( + ret = bgp_flowspec_bitmask_decode( type_util, nlri_content+offset, len - offset, @@ -221,11 +221,11 @@ void bgp_fs_nlri_get_string(unsigned char *nlri_content, size_t len, ptr += len_written; break; case FLOWSPEC_FRAGMENT: - ret = bgp_flowspec_fragment_type_decode( - type_util, - nlri_content + offset, - len - offset, local_string, - &error); + ret = bgp_flowspec_bitmask_decode( + type_util, + nlri_content+offset, + len - offset, + local_string, &error); if (ret <= 0) break; if (json_path) { |