summaryrefslogtreecommitdiffstats
path: root/src/plugins/nat/in2out_ed.c
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2020-06-03 11:47:55 +0200
committerOle Troan <ot@cisco.com>2020-06-03 11:48:50 +0200
commitec62d0a436be00bcc084a56548c8c7fa55b2cb61 (patch)
treeb80ef1eb7340165c0cabf348198e0084c36990f4 /src/plugins/nat/in2out_ed.c
parentbe360ee4d7d34954bd93ed852c9d7bf9109ce6fb (diff)
nat: refactor mss_clamping to not depend on snat_main_t
Type: refactor Signed-off-by: Ole Troan <ot@cisco.com> Change-Id: I1110e425859a4f1f07952c91b50f263cb7323836
Diffstat (limited to 'src/plugins/nat/in2out_ed.c')
-rw-r--r--src/plugins/nat/in2out_ed.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/nat/in2out_ed.c b/src/plugins/nat/in2out_ed.c
index 06e6772840b..9b10d9df7f6 100644
--- a/src/plugins/nat/in2out_ed.c
+++ b/src/plugins/nat/in2out_ed.c
@@ -32,6 +32,7 @@
#include <nat/nat_syslog.h>
#include <nat/nat_ha.h>
#include <nat/nat44/ed_inlines.h>
+#include <nat/lib/nat_inlines.h>
static char *nat_in2out_ed_error_strings[] = {
#define _(sym,string) string,
@@ -1096,7 +1097,7 @@ nat44_ed_in2out_fast_path_node_fn_inline (vlib_main_t * vm,
tcp0->dst_port = s0->ext_host_port;
ip0->dst_address.as_u32 = s0->ext_host_addr.as_u32;
}
- mss_clamping (sm, tcp0, &sum0);
+ mss_clamping (sm->mss_clamping, tcp0, &sum0);
tcp0->checksum = ip_csum_fold (sum0);
}
tcp_packets++;
@@ -1406,7 +1407,7 @@ nat44_ed_in2out_slow_path_node_fn_inline (vlib_main_t * vm,
tcp0->dst_port = s0->ext_host_port;
ip0->dst_address.as_u32 = s0->ext_host_addr.as_u32;
}
- mss_clamping (sm, tcp0, &sum0);
+ mss_clamping (sm->mss_clamping, tcp0, &sum0);
tcp0->checksum = ip_csum_fold (sum0);
}
tcp_packets++;