@@ -524,7 +524,8 @@ int NHTFlowCache::put_pkt(Packet& packet)
524524 const std::variant<FlowKeyv4, FlowKeyv6> reversed_key = *FlowKeyFactory::create_reversed_key (&packet.src_ip , &packet.dst_ip ,
525525 packet.src_port , packet.dst_port , packet.ip_proto , static_cast <IP>(packet.ip_version ));
526526
527- auto [row, flow_identification] = find_flow_index (direct_key, reversed_key, packet.vlan_id );
527+ auto [row, flow_identification] =
528+ find_flow_index (direct_key, reversed_key, packet.vlan_id );
528529
529530 if (std::holds_alternative<size_t >(flow_identification)) {
530531 const size_t hash_value = std::get<size_t >(flow_identification);
@@ -537,9 +538,10 @@ int NHTFlowCache::put_pkt(Packet& packet)
537538 if (!std::holds_alternative<std::pair<size_t , bool >>(flow_identification)) {
538539 std::cout << std::endl;
539540 }
540- const auto [flow_index, source_to_destination] = std::get<std::pair<size_t , bool >>(flow_identification);
541- const size_t hash_value = m_flow_table[flow_index]-> m_flow . flow_hash ;
541+ const auto & [flow_index, source_to_destination] = std::get<std::pair<size_t , bool >>(flow_identification);
542+
542543#ifdef WITH_CTT
544+ const size_t hash_value = m_flow_table[flow_index]->m_flow .flow_hash ;
543545 const bool flow_is_waiting_for_export = !try_to_export_delayed_flow (packet, flow_index) && m_flow_table[flow_index]->is_waiting_for_export ;
544546#else
545547 constexpr bool flow_is_waiting_for_export = false ;
0 commit comments