session: transport endpt cleanup on owner thread
[vpp.git] / src / vnet / udp / udp_input.c
index f6c55f6..1c1d9e8 100644 (file)
@@ -115,6 +115,7 @@ udp_connection_accept (udp_connection_t * listener, session_dgram_hdr_t * hdr,
   uc->c_fib_index = listener->c_fib_index;
   uc->mss = listener->mss;
   uc->flags |= UDP_CONN_F_CONNECTED;
+  uc->cfg_flags = listener->cfg_flags;
 
   if (session_dgram_accept (&uc->connection, listener->c_s_index,
                            listener->c_thread_index))
@@ -255,6 +256,7 @@ udp46_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
        {
          u8 queue_event = 1;
          uc0 = udp_connection_from_transport (session_get_transport (s0));
+         uc0->sw_if_index = vnet_buffer (b[0])->sw_if_index[VLIB_RX];
          if (uc0->flags & UDP_CONN_F_CONNECTED)
            {
              if (s0->thread_index != thread_index)
@@ -298,6 +300,7 @@ udp46_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
                  goto done;
                }
              s0 = session_get (uc0->c_s_index, uc0->c_thread_index);
+             uc0->sw_if_index = vnet_buffer (b[0])->sw_if_index[VLIB_RX];
              error0 = UDP_ERROR_ACCEPT;
            }
          udp_connection_enqueue (uc0, s0, &hdr0, thread_index, b[0], 1,