From 9ff9cb1d55b218ed627462010ec00d284236b8c4 Mon Sep 17 00:00:00 2001 From: hyung-hwan Date: Sun, 1 Jul 2018 07:37:01 +0000 Subject: [PATCH] fixed the wrong call to QSE_CPP_CALL_DESTRUCTOR to QSE_CPP_DELETE_WITH_MMGR --- qse/include/qse/si/Thread.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qse/include/qse/si/Thread.hpp b/qse/include/qse/si/Thread.hpp index 73a3a360..579d6d18 100644 --- a/qse/include/qse/si/Thread.hpp +++ b/qse/include/qse/si/Thread.hpp @@ -169,7 +169,7 @@ public: ThreadL (Mmgr* mmgr = QSE_NULL) QSE_CPP_NOEXCEPT: Thread(mmgr), __lfunc(nullptr) {} ~ThreadL () QSE_CPP_NOEXCEPT { - if (this->__lfunc) QSE_CPP_CALL_DESTRUCTOR (this->__lfunc, Callable, this->getMmgr()); //delete this->__lfunc; + if (this->__lfunc) QSE_CPP_DELETE_WITH_MMGR (this->__lfunc, Callable, this->getMmgr()); //delete this->__lfunc; } static int call_func (qse_thr_t* thr, void* ctx) @@ -183,7 +183,7 @@ public: //int start (T f, int flags) QSE_CPP_NOEXCEPT { if (this->thr.__state == QSE_THR_RUNNING) return -1; - if (this->__lfunc) QSE_CPP_CALL_DESTRUCTOR (this->__lfunc, Callable, this->getMmgr()); //delete this->__lfunc; + if (this->__lfunc) QSE_CPP_DELETE_WITH_MMGR (this->__lfunc, Callable, this->getMmgr()); //delete this->__lfunc; try { // TODO: are there any ways to achieve this without memory allocation?