summaryrefslogtreecommitdiffstats
path: root/src/H5mpi.c
diff options
context:
space:
mode:
authorjhendersonHDF <jhenderson@hdfgroup.org>2021-02-24 10:24:47 (GMT)
committerGitHub <noreply@github.com>2021-02-24 10:24:47 (GMT)
commit7c507003c7585837dace9bbbec9fde7a80802dbf (patch)
treeaed5375b53055c2c57cadf4886f2eb3aaccd602f /src/H5mpi.c
parent2d8913c615b337d18fc35c74decff9a589a632d1 (diff)
downloadhdf5-7c507003c7585837dace9bbbec9fde7a80802dbf.zip
hdf5-7c507003c7585837dace9bbbec9fde7a80802dbf.tar.gz
hdf5-7c507003c7585837dace9bbbec9fde7a80802dbf.tar.bz2
Fix for HDFFV-11109 - Copy MPI comm and info object into output FAPL from H5F_get_access_plist (#342) (#374)
* Avoid freeing MPI_COMM_WORLD in H5_mpi_comm_free * Copy MPI Comm and Info to new FAPL in H5F_get_access_plist
Diffstat (limited to 'src/H5mpi.c')
-rw-r--r--src/H5mpi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/H5mpi.c b/src/H5mpi.c
index 58b4ce6..9749721 100644
--- a/src/H5mpi.c
+++ b/src/H5mpi.c
@@ -210,7 +210,7 @@ H5_mpi_comm_free(MPI_Comm *comm)
HGOTO_ERROR(H5E_INTERNAL, H5E_BADVALUE, FAIL, "comm pointer cannot be NULL")
/* Free the communicator */
- if (MPI_COMM_NULL != *comm)
+ if (MPI_COMM_WORLD != *comm && MPI_COMM_NULL != *comm)
MPI_Comm_free(comm);
*comm = MPI_COMM_NULL;