From eb1f261aec236c177bcf1a6af7fb469cbbcaa95e Mon Sep 17 00:00:00 2001 From: Augustin Degomme Date: Tue, 10 Apr 2018 20:21:37 +0200 Subject: [PATCH] only test for these on non-root processes --- src/smpi/bindings/smpi_pmpi_coll.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/smpi/bindings/smpi_pmpi_coll.cpp b/src/smpi/bindings/smpi_pmpi_coll.cpp index 9b9fa96dfe..b4a298c00a 100644 --- a/src/smpi/bindings/smpi_pmpi_coll.cpp +++ b/src/smpi/bindings/smpi_pmpi_coll.cpp @@ -122,7 +122,7 @@ int PMPI_Gatherv(void *sendbuf, int sendcount, MPI_Datatype sendtype, void *recv retval = MPI_ERR_TYPE; } else if (( sendbuf != MPI_IN_PLACE) && (sendcount <0)){ retval = MPI_ERR_COUNT; - } else if (recvcounts == nullptr || displs == nullptr) { + } else if ((comm->rank() == root) && (recvcounts == nullptr || displs == nullptr)) { retval = MPI_ERR_ARG; } else { char* sendtmpbuf = static_cast(sendbuf); -- 2.20.1