From 73e177ec59c6482f70cb460f4bdf1f84d5a727a7 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Sat, 7 Oct 2017 22:25:10 +0800 Subject: [PATCH] Regex: Do not use sized deallocation to support more compilers --- src/regex_impl.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/regex_impl.hh b/src/regex_impl.hh index 535cdf92..9c2f26af 100644 --- a/src/regex_impl.hh +++ b/src/regex_impl.hh @@ -118,7 +118,7 @@ public: for (size_t i = m_program.save_count-1; i > 0; --i) saves->pos[i].~Iterator(); saves->~Saves(); - ::operator delete(saves, sizeof(Saves) + (m_program.save_count-1) * sizeof(Iterator)); + ::operator delete(saves); } }