aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet')
-rwxr-xr-xsrc/vnet/tcp/tcp_input.c23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/vnet/tcp/tcp_input.c b/src/vnet/tcp/tcp_input.c
index cf74fb91ce1..59b01047026 100755
--- a/src/vnet/tcp/tcp_input.c
+++ b/src/vnet/tcp/tcp_input.c
@@ -3221,6 +3221,18 @@ tcp46_listen_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
n_left_from -= 1;
b0 = vlib_get_buffer (vm, bi0);
+
+ if (is_ip4)
+ {
+ ip40 = vlib_buffer_get_current (b0);
+ th0 = tcp_buffer_hdr (b0);
+ }
+ else
+ {
+ ip60 = vlib_buffer_get_current (b0);
+ th0 = tcp_buffer_hdr (b0);
+ }
+
lc0 = tcp_listener_get (vnet_buffer (b0)->tcp.connection_index);
if (PREDICT_FALSE (lc0 == 0))
{
@@ -3236,17 +3248,6 @@ tcp46_listen_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
tcp_connection_del (tc0);
}
- if (is_ip4)
- {
- ip40 = vlib_buffer_get_current (b0);
- th0 = tcp_buffer_hdr (b0);
- }
- else
- {
- ip60 = vlib_buffer_get_current (b0);
- th0 = tcp_buffer_hdr (b0);
- }
-
/* Create child session. For syn-flood protection use filter */
/* 1. first check for an RST: handled in dispatch */