Skip to content

Commit 503de6c

Browse files
authored
Merge pull request #3933 from hppritcha/topic/fix_s1_bug
pmix/s1: fix problems with ref counting in s1
2 parents 71333a4 + 2fa0c4c commit 503de6c

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

opal/mca/pmix/s1/pmix_s1.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
* Copyright (c) 2014-2016 Research Organization for Information Science
55
* and Technology (RIST). All rights reserved.
66
* Copyright (c) 2016 Cisco Systems, Inc. All rights reserved.
7+
* Copyright (c) 2017 Los Alamos National Security, LLC. All
8+
* rights reserved.
79
* $COPYRIGHT$
810
*
911
* Additional copyrights may follow
@@ -156,6 +158,7 @@ static int s1_init(opal_list_t *ilist)
156158
opal_process_name_t wildcard_rank;
157159

158160
if (0 < pmix_init_count) {
161+
++pmix_init_count;
159162
return OPAL_SUCCESS;
160163
}
161164

@@ -446,11 +449,10 @@ static int s1_fini(void) {
446449

447450
if (0 == --pmix_init_count) {
448451
PMI_Finalize ();
452+
// teardown hash table
453+
opal_pmix_base_hash_finalize();
449454
}
450455

451-
// teardown hash table
452-
opal_pmix_base_hash_finalize();
453-
454456
return OPAL_SUCCESS;
455457
}
456458

0 commit comments

Comments
 (0)