From 40be3d896c622a88722057a26c859f292ee4d84d Mon Sep 17 00:00:00 2001 From: Ralph Castain Date: Wed, 17 Feb 2010 22:59:19 +0000 Subject: [PATCH] Ensure we set an error code when leaving, correctly check for slot_list_set return status This commit was SVN r22643. --- ompi/runtime/ompi_mpi_init.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ompi/runtime/ompi_mpi_init.c b/ompi/runtime/ompi_mpi_init.c index a48a52dc19..ca6237dc78 100644 --- a/ompi/runtime/ompi_mpi_init.c +++ b/ompi/runtime/ompi_mpi_init.c @@ -443,7 +443,7 @@ int ompi_mpi_init(int argc, char **argv, int requested, int *provided) goto error; } ret = opal_paffinity_base_slot_list_set((long)ORTE_PROC_MY_NAME->vpid, opal_paffinity_base_slot_list); - if (OPAL_ERR_NOT_FOUND != ret) { + if (OPAL_SUCCESS != ret && OPAL_ERR_NOT_FOUND != ret) { error = "opal_paffinity_base_slot_list_set() returned an error"; goto error; } @@ -453,6 +453,7 @@ int ompi_mpi_init(int argc, char **argv, int requested, int *provided) int phys_cpu; orte_node_rank_t nrank; if (ORTE_NODE_RANK_INVALID == (nrank = orte_ess.get_node_rank(ORTE_PROC_MY_NAME))) { + ret = OMPI_ERR_BAD_PARAM; error = "Could not get node rank - cannot set processor affinity"; goto error; }