Skip to content

Commit 7aeb6f1

Browse files
committed
++ cache
1 parent 5318107 commit 7aeb6f1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

storage/cache.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,8 @@ int NHTFlowCache::put_pkt(Packet& packet)
528528
auto [row, flow_identification] =
529529
find_flow_index(direct_key, reversed_key, packet.vlan_id);
530530

531-
if (const size_t hash_value = std::holds_alternative<size_t>(flow_identification)) {
531+
if (std::holds_alternative<size_t>(flow_identification)) {
532+
const size_t hash_value = std::get<size_t>(flow_identification);
532533
const size_t empty_place = get_empty_place(row, packet.ts) + (hash_value & m_line_mask);
533534
create_record(packet, empty_place, hash_value);
534535
export_expired(packet.ts);

0 commit comments

Comments
 (0)