From b55e6465ce7ba5013b44dfe74dc981b1f13fa99f Mon Sep 17 00:00:00 2001 From: mat <26722564+matcool@users.noreply.github.com> Date: Wed, 11 Oct 2023 15:23:13 -0300 Subject: [PATCH] fix gnustl vector dtor --- loader/include/Geode/c++stl/gnustl.hpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/loader/include/Geode/c++stl/gnustl.hpp b/loader/include/Geode/c++stl/gnustl.hpp index 668c0333..a7d87cb6 100644 --- a/loader/include/Geode/c++stl/gnustl.hpp +++ b/loader/include/Geode/c++stl/gnustl.hpp @@ -405,7 +405,12 @@ namespace gd { } ~vector() { - if (m_start) delete m_start; + if (m_start) { + for (auto& x : *this) { + x.~T(); + } + delete m_start; + } } size_t size() const {