From 43e0c5bfef4372fbbd990d2ef572b41d97c05a97 Mon Sep 17 00:00:00 2001 From: Ralph Castain Date: Fri, 23 Oct 2015 12:26:49 -0700 Subject: [PATCH] Release the allocator list items from the list before destructing --- opal/mca/allocator/basic/allocator_basic.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/opal/mca/allocator/basic/allocator_basic.c b/opal/mca/allocator/basic/allocator_basic.c index b988db1ddcc..22e1bc2a189 100644 --- a/opal/mca/allocator/basic/allocator_basic.c +++ b/opal/mca/allocator/basic/allocator_basic.c @@ -359,6 +359,10 @@ int mca_allocator_basic_compact(mca_allocator_base_module_t * mem) int mca_allocator_basic_finalize(mca_allocator_base_module_t * base) { mca_allocator_basic_module_t* module = (mca_allocator_basic_module_t*)base; + // clear the list as we don't own these bits + while (NULL != opal_list_remove_first(&module->seg_list)) { + continue; + } OBJ_DESTRUCT(&module->seg_list); OBJ_DESTRUCT(&module->seg_lock); OBJ_DESTRUCT(&module->seg_descriptors);