From ab0cca29ffec238af370fd34d99c054eadfe05c3 Mon Sep 17 00:00:00 2001 From: joaquintides Date: Tue, 21 Mar 2023 15:41:59 +0100 Subject: [PATCH] provide small initial size to cfoa::table to prevent capacity overflows --- cfoa.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cfoa.hpp b/cfoa.hpp index e19465a2..6f8565ba 100644 --- a/cfoa.hpp +++ b/cfoa.hpp @@ -1298,7 +1298,7 @@ public: const_iterator>::type; table( - std::size_t n=0,const Hash& h_=Hash(),const Pred& pred_=Pred(), + std::size_t n=1000,const Hash& h_=Hash(),const Pred& pred_=Pred(), const Allocator& al_=Allocator()): hash_base{empty_init,h_},pred_base{empty_init,pred_}, allocator_base{empty_init,al_},size_{0},arrays(new_arrays(n)),