From f97ccfbf56005c0966af2d7204b98dc77a2d0257 Mon Sep 17 00:00:00 2001 From: gianpaolopalma Date: Fri, 20 Jun 2014 13:55:19 +0000 Subject: [PATCH] Added destructor to HeapMaxPriorityQueue --- vcg/space/index/kdtree/priorityqueue.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/vcg/space/index/kdtree/priorityqueue.h b/vcg/space/index/kdtree/priorityqueue.h index 13aae024..956dc54f 100755 --- a/vcg/space/index/kdtree/priorityqueue.h +++ b/vcg/space/index/kdtree/priorityqueue.h @@ -43,6 +43,13 @@ public: mMaxSize = 0; } + ~HeapMaxPriorityQueue() + { + if (mElements) + delete[] mElements; + } + + inline void setMaxSize(int maxSize) { if (mMaxSize!=maxSize)