summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Ray <aray@google.com>2013-07-17 16:57:21 -0700
committerAlex Ray <aray@google.com>2013-07-30 13:57:01 -0700
commit0d8f3d6c452883ab7295573c4ff7437d68d1d936 (patch)
treeffda5b41146be61a9b455345c54334bb4d652079
parent946003ae6472ab4661c10d11c2b6ded42fe701ca (diff)
downloadsystem_core-0d8f3d6c452883ab7295573c4ff7437d68d1d936.zip
system_core-0d8f3d6c452883ab7295573c4ff7437d68d1d936.tar.gz
system_core-0d8f3d6c452883ab7295573c4ff7437d68d1d936.tar.bz2
libutils: give BasicHashtableImpl a virtual destructor
Change-Id: I4ec590b060d732af5fe525670becbe778684247b
-rw-r--r--include/utils/BasicHashtable.h1
-rw-r--r--libs/utils/BasicHashtable.cpp4
2 files changed, 5 insertions, 0 deletions
diff --git a/include/utils/BasicHashtable.h b/include/utils/BasicHashtable.h
index 7a6c96c..c235d62 100644
--- a/include/utils/BasicHashtable.h
+++ b/include/utils/BasicHashtable.h
@@ -52,6 +52,7 @@ protected:
BasicHashtableImpl(size_t entrySize, bool hasTrivialDestructor,
size_t minimumInitialCapacity, float loadFactor);
BasicHashtableImpl(const BasicHashtableImpl& other);
+ virtual ~BasicHashtableImpl();
void dispose();
diff --git a/libs/utils/BasicHashtable.cpp b/libs/utils/BasicHashtable.cpp
index fd51b7b..491d9e9 100644
--- a/libs/utils/BasicHashtable.cpp
+++ b/libs/utils/BasicHashtable.cpp
@@ -42,6 +42,10 @@ BasicHashtableImpl::BasicHashtableImpl(const BasicHashtableImpl& other) :
}
}
+BasicHashtableImpl::~BasicHashtableImpl()
+{
+}
+
void BasicHashtableImpl::dispose() {
if (mBuckets) {
releaseBuckets(mBuckets, mBucketCount);