From c99a58faee741311f78efc43081a2cbb6acea763 Mon Sep 17 00:00:00 2001 From: Rafael Kitover Date: Thu, 3 Aug 2017 16:29:37 -0700 Subject: [PATCH] fix a memory leak due to wrong syntax In C++ arrays are deleted with `delete[]` and not `delete`. --- src/common/array.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/array.h b/src/common/array.h index bde64309..fde749e3 100644 --- a/src/common/array.h +++ b/src/common/array.h @@ -53,7 +53,7 @@ template class Array ~Array() { - if (dealloc) delete m_p; + if (dealloc) delete[] m_p; } size_type size() const