Skip to content

Commit b3559a4

Browse files
authored
Merge pull request #3861 from hppritcha/topic/fix_cray_pmix_problem_3
pmix/cray: fix handling of multiple finis
2 parents 25a3465 + 2623cf6 commit b3559a4

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

opal/mca/pmix/cray/pmix_cray.c

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -558,17 +558,22 @@ static int cray_fini(void) {
558558
}
559559

560560
if (0 == --pmix_init_count) {
561+
562+
opal_output_verbose(10, opal_pmix_base_framework.framework_output,
563+
"%s pmix:cray: calling PMI2_Finalize",
564+
OPAL_NAME_PRINT(pmix_pname));
565+
561566
PMI2_Finalize();
562-
}
563567

564-
if (NULL != pmix_kvs_name) {
565-
free(pmix_kvs_name);
566-
pmix_kvs_name = NULL;
567-
}
568+
if (NULL != pmix_kvs_name) {
569+
free(pmix_kvs_name);
570+
pmix_kvs_name = NULL;
571+
}
568572

569-
if (NULL != pmix_lranks) {
570-
free(pmix_lranks);
571-
pmix_lranks = NULL;
573+
if (NULL != pmix_lranks) {
574+
free(pmix_lranks);
575+
pmix_lranks = NULL;
576+
}
572577
}
573578

574579
return OPAL_SUCCESS;

0 commit comments

Comments
 (0)