8200111: MallocArrayAllocator::free should not take a length parameter
Reviewed-by: gtriantafill, coleenp, tschatzl
--- a/src/hotspot/share/memory/allocation.hpp Thu Mar 22 20:21:19 2018 -0700
+++ b/src/hotspot/share/memory/allocation.hpp Thu Mar 22 12:34:31 2018 +0100
@@ -549,7 +549,7 @@
static size_t size_for(size_t length);
static E* allocate(size_t length, MEMFLAGS flags);
- static void free(E* addr, size_t length);
+ static void free(E* addr);
};
#endif // SHARE_VM_MEMORY_ALLOCATION_HPP
--- a/src/hotspot/share/memory/allocation.inline.hpp Thu Mar 22 20:21:19 2018 -0700
+++ b/src/hotspot/share/memory/allocation.inline.hpp Thu Mar 22 12:34:31 2018 +0100
@@ -105,7 +105,7 @@
}
template<class E>
-void MallocArrayAllocator<E>::free(E* addr, size_t /*length*/) {
+void MallocArrayAllocator<E>::free(E* addr) {
FreeHeap(addr);
}
@@ -152,7 +152,7 @@
template<class E>
void ArrayAllocator<E>::free_malloc(E* addr, size_t length) {
- MallocArrayAllocator<E>::free(addr, length);
+ MallocArrayAllocator<E>::free(addr);
}
template<class E>