From facf8c5e98b22a615d50a56f0a2ae94515ef0bad Mon Sep 17 00:00:00 2001 From: KAWASHIMA Takahiro Date: Tue, 23 Jul 2019 08:45:17 +0900 Subject: [PATCH] pcollreq/mpif-h: fix MPIX_Alltoallw_init() binding These issues were introduced in the recent commit b71af0eca0. This commit fixes Coverity CID 1451661 and 1451660. Though `c_info` part was an actual bug, the `c_sendtypes` part was not. Signed-off-by: KAWASHIMA Takahiro --- ompi/mpiext/pcollreq/mpif-h/alltoallw_init_f.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ompi/mpiext/pcollreq/mpif-h/alltoallw_init_f.c b/ompi/mpiext/pcollreq/mpif-h/alltoallw_init_f.c index a90047c093..0fae1e194d 100644 --- a/ompi/mpiext/pcollreq/mpif-h/alltoallw_init_f.c +++ b/ompi/mpiext/pcollreq/mpif-h/alltoallw_init_f.c @@ -76,7 +76,7 @@ void ompix_alltoallw_init_f(char *sendbuf, MPI_Fint *sendcounts, MPI_Fint *comm, MPI_Fint *info, MPI_Fint *request, MPI_Fint *ierr) { MPI_Comm c_comm; - MPI_Datatype *c_sendtypes, *c_recvtypes; + MPI_Datatype *c_sendtypes = NULL, *c_recvtypes; MPI_Info c_info; MPI_Request c_request; int size, c_ierr; @@ -86,6 +86,7 @@ void ompix_alltoallw_init_f(char *sendbuf, MPI_Fint *sendcounts, OMPI_ARRAY_NAME_DECL(rdispls); c_comm = PMPI_Comm_f2c(*comm); + c_info = PMPI_Info_f2c(*info); size = OMPI_COMM_IS_INTER(c_comm)?ompi_comm_remote_size(c_comm):ompi_comm_size(c_comm); if (!OMPI_IS_FORTRAN_IN_PLACE(sendbuf)) {