fix memory leak when unit migrate or del tenant happens

This commit is contained in:
jh0
2021-07-27 15:39:13 +08:00
committed by wangzelin.wzl
parent 85d7d1e6f8
commit 9d77e24a32
8 changed files with 29 additions and 5 deletions

View File

@ -1080,7 +1080,9 @@ void ObPlanCache::dec_ref_count()
if (ref_count > 0) {
} else if (0 == ref_count) {
// delete
this->~ObPlanCache();
this->set_valid(false);
destroy();
// this->~ObPlanCache();
} else if (ref_count < 0) {
BACKTRACE(ERROR, true, "Plan Cache %p ref count < 0, ref_count = %ld", this, ref_count);
}