Skip to content

Commit f5e61b4

Browse files
author
Ralph Castain
committed
Cleanup the MPI_Finalize_c/f tests
Fix a few errors: * copy the key across for calls to PMIx job_control * re-initialize orte_process_info.aliases in case someone foolishly re-calls orte_init * protect the ompi errcodes in case someone foolishly re-calls MPI_Init Signed-off-by: Ralph Castain <[email protected]> (cherry picked from commit a87baec)
1 parent 386ae5a commit f5e61b4

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

ompi/errhandler/errcode-internal.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
* Copyright (c) 2010 Oracle and/or its affiliates. All rights reserved.
1515
* Copyright (c) 2012 Los Alamos National Security, LLC. All rights
1616
* reserved.
17+
* Copyright (c) 2018 Intel, Inc. All rights reserved.
1718
* $COPYRIGHT$
1819
*
1920
* Additional copyrights may follow
@@ -69,7 +70,7 @@ static inline int ompi_errcode_get_mpi_code(int errcode)
6970
it */
7071
for (i = 0; i < ompi_errcode_intern_lastused; i++) {
7172
errc = (ompi_errcode_intern_t *)opal_pointer_array_get_item(&ompi_errcodes_intern, i);
72-
if (errc->code == errcode) {
73+
if (NULL != errc && errc->code == errcode) {
7374
ret = errc->mpi_code;
7475
break;
7576
}

opal/mca/pmix/pmix2x/pmix2x_server_north.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
22
/*
3-
* Copyright (c) 2014-2017 Intel, Inc. All rights reserved.
3+
* Copyright (c) 2014-2018 Intel, Inc. All rights reserved.
44
* Copyright (c) 2014-2017 Research Organization for Information Science
55
* and Technology (RIST). All rights reserved.
66
* Copyright (c) 2014-2015 Mellanox Technologies, Inc.

orte/orted/pmix/pmix_server_gen.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* All rights reserved.
1414
* Copyright (c) 2009 Cisco Systems, Inc. All rights reserved.
1515
* Copyright (c) 2011 Oak Ridge National Labs. All rights reserved.
16-
* Copyright (c) 2013-2017 Intel, Inc. All rights reserved.
16+
* Copyright (c) 2013-2018 Intel, Inc. All rights reserved.
1717
* Copyright (c) 2014-2017 Mellanox Technologies, Inc.
1818
* All rights reserved.
1919
* Copyright (c) 2014 Research Organization for Information Science

orte/util/proc_info.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* Copyright (c) 2009-2016 Cisco Systems, Inc. All rights reserved.
1313
* Copyright (c) 2012 Los Alamos National Security, LLC.
1414
* All rights reserved.
15-
* Copyright (c) 2014-2017 Intel, Inc. All rights reserved.
15+
* Copyright (c) 2014-2018 Intel, Inc. All rights reserved.
1616
* Copyright (c) 2016 IBM Corporation. All rights reserved.
1717
* $COPYRIGHT$
1818
*
@@ -327,6 +327,7 @@ int orte_proc_info_finalize(void)
327327
orte_process_info.proc_type = ORTE_PROC_TYPE_NONE;
328328

329329
opal_argv_free(orte_process_info.aliases);
330+
orte_process_info.aliases = NULL;
330331

331332
init = false;
332333
return ORTE_SUCCESS;

0 commit comments

Comments
 (0)