}
if (total_count == 0) {
+ xbt_free(disps);
return MPI_ERR_COUNT;
}
if (mpi_errno) return(mpi_errno);
}
-return MPI_SUCCESS;
+ xbt_free(disps);
+ xbt_free(tmp_recvbuf);
+
+ return MPI_SUCCESS;
}
int mask, dst_tree_root, my_tree_root, j, k;
int received;
MPI_Datatype sendtype, recvtype;
- int nprocs_completed, tmp_mask, tree_root, is_commutative;
+ int nprocs_completed, tmp_mask, tree_root, is_commutative=0;
comm_size = smpi_comm_size(comm);
rank = smpi_comm_rank(comm);