tests: changes for scapy 2.4.3 migration
[vpp.git] / src / plugins / map / ip6_map_t.c
index 6e9c0d7..7999507 100644 (file)
@@ -169,7 +169,7 @@ ip6_map_t_icmp (vlib_main_t * vm,
            {
              // Send to fragmentation node if necessary
              vnet_buffer (p0)->ip_frag.mtu = vnet_buffer (p0)->map_t.mtu;
-             vnet_buffer (p0)->ip_frag.next_index = IP4_FRAG_NEXT_IP4_LOOKUP;
+             vnet_buffer (p0)->ip_frag.next_index = IP_FRAG_NEXT_IP4_LOOKUP;
              next0 = IP6_MAPT_ICMP_NEXT_IP4_FRAG;
            }
        err0:
@@ -288,7 +288,7 @@ ip6_map_t_fragmented (vlib_main_t * vm,
                  // Send to fragmentation node if necessary
                  vnet_buffer (p0)->ip_frag.mtu = vnet_buffer (p0)->map_t.mtu;
                  vnet_buffer (p0)->ip_frag.next_index =
-                   IP4_FRAG_NEXT_IP4_LOOKUP;
+                   IP_FRAG_NEXT_IP4_LOOKUP;
                  next0 = IP6_MAPT_FRAGMENTED_NEXT_IP4_FRAG;
                }
            }
@@ -441,7 +441,7 @@ ip6_map_t_tcp_udp (vlib_main_t * vm,
                  // Send to fragmentation node if necessary
                  vnet_buffer (p0)->ip_frag.mtu = vnet_buffer (p0)->map_t.mtu;
                  vnet_buffer (p0)->ip_frag.next_index =
-                   IP4_FRAG_NEXT_IP4_LOOKUP;
+                   IP_FRAG_NEXT_IP4_LOOKUP;
                  next0 = IP6_MAPT_TCP_UDP_NEXT_IP4_FRAG;
                }
            }
@@ -491,7 +491,7 @@ ip6_map_t (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
          n_left_to_next -= 1;
          error0 = MAP_ERROR_NONE;
          p0 = vlib_get_buffer (vm, pi0);
-         u16 l4_dst_port = vnet_buffer (p0)->ip.reass.l4_dst_port;
+         u16 l4_src_port = vnet_buffer (p0)->ip.reass.l4_src_port;
 
          ip60 = vlib_buffer_get_current (p0);
 
@@ -534,7 +534,7 @@ ip6_map_t (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
              (vnet_buffer (p0)->map_t.v6.frag_offset
               && ip6_frag_hdr_offset (frag0)))
            {
-             map_port0 = l4_dst_port;
+             map_port0 = l4_src_port;
              next0 = IP6_MAPT_NEXT_MAPT_FRAGMENTED;
            }
          else
@@ -547,7 +547,7 @@ ip6_map_t (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
              vnet_buffer (p0)->map_t.checksum_offset =
                vnet_buffer (p0)->map_t.v6.l4_offset + 16;
              next0 = IP6_MAPT_NEXT_MAPT_TCP_UDP;
-             map_port0 = l4_dst_port;
+             map_port0 = l4_src_port;
            }
          else
            if (PREDICT_TRUE
@@ -559,7 +559,7 @@ ip6_map_t (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
              vnet_buffer (p0)->map_t.checksum_offset =
                vnet_buffer (p0)->map_t.v6.l4_offset + 6;
              next0 = IP6_MAPT_NEXT_MAPT_TCP_UDP;
-             map_port0 = l4_dst_port;
+             map_port0 = l4_src_port;
            }
          else if (vnet_buffer (p0)->map_t.v6.l4_protocol ==
                   IP_PROTOCOL_ICMP6)
@@ -576,7 +576,7 @@ ip6_map_t (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
                      u8_ptr_add (ip60,
                                  vnet_buffer (p0)->map_t.v6.l4_offset))->
                  code == ICMP6_echo_request)
-               map_port0 = l4_dst_port;
+               map_port0 = l4_src_port;
            }
          else
            {