From b19912c9b21a3892ef56009616d0e6f518607502 Mon Sep 17 00:00:00 2001 From: Matt Benjamin Date: Sat, 19 Dec 2015 18:32:42 -0500 Subject: [PATCH] cohort_lru: use correct new/delete operator pair Signed-off-by: Matt Benjamin --- src/common/cohort_lru.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/cohort_lru.h b/src/common/cohort_lru.h index cdabb1e5bef81..2f83b4230556f 100644 --- a/src/common/cohort_lru.h +++ b/src/common/cohort_lru.h @@ -284,7 +284,7 @@ namespace cohort { ~Partition() { if (csz) - delete[] cache; + ::operator delete(cache); } }; @@ -323,7 +323,7 @@ namespace cohort { Partition& p = part[ix]; if (csz) { p.csz = csz; - p.cache = (T**) calloc(csz, sizeof(T*)); + p.cache = (T**) ::operator new(csz * sizeof(T*)); } locks.push_back(&p.lock); } -- 2.39.5