From 6ec6e320d8d73bb09a02fc46d18302e08b07daf7 Mon Sep 17 00:00:00 2001 From: orignal Date: Thu, 29 Oct 2026 15:24:28 -0400 Subject: [PATCH] use boost::unordered_flat_map for tags if boost >= 1.81 --- libi2pd/Garlic.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/libi2pd/Garlic.h b/libi2pd/Garlic.h index 718add61..e2b23a4b 100644 --- a/libi2pd/Garlic.h +++ b/libi2pd/Garlic.h @@ -19,6 +19,10 @@ #include #include #include +#include +#if (BOOST_VERSION >= 108100) // 1.81 +#include +#endif #include "Crypto.h" #include "I2NPProtocol.h" #include "LeaseSet.h" @@ -329,7 +333,11 @@ namespace garlic // incoming int m_NumRatchetInboundTags; std::unordered_map, std::hash > > m_Tags; +#if (BOOST_VERSION >= 108100) // 1.81 + boost::unordered_flat_map m_ECIESx25519Tags; // session tag -> session +#else std::unordered_map m_ECIESx25519Tags; // session tag -> session +#endif // DeliveryStatus std::mutex m_DeliveryStatusSessionsMutex; std::unordered_map m_DeliveryStatusSessions; // msgID -> session