From 99249a22e40ddc7d280edaaa238a3e0d7b29c337 Mon Sep 17 00:00:00 2001 From: Michael Sippel Date: Wed, 13 Dec 2023 22:51:04 +0100 Subject: [PATCH] call destructor for all items in ~Chunk() --- redGrapes/util/chunked_list.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/redGrapes/util/chunked_list.hpp b/redGrapes/util/chunked_list.hpp index 622551fd..192e9658 100644 --- a/redGrapes/util/chunked_list.hpp +++ b/redGrapes/util/chunked_list.hpp @@ -191,7 +191,7 @@ struct ChunkedList ~Chunk() { - for( Item * item = first_item; item <= last_item; item++ ) + for( Item * item = first_item; item < ( this->first_item + T_chunk_size ); item++ ) item->~Item(); }