Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
correct a few mistakes with waitall, waitany, wait
[simgrid.git] / src / smpi / smpi_mpi_dt.c
index bc03ee9f5eb7f76567ea936e562b5cded1ee0834..0db4d81a21ec0d57fa7e5cdbd935bd0156c5f102 100644 (file)
@@ -1460,7 +1460,7 @@ MPI_Op smpi_op_new(MPI_User_function * function, int commute)
 
 int smpi_op_is_commute(MPI_Op op)
 {
-  return op-> is_commute;
+  return (op==MPI_OP_NULL) ? 1 : op-> is_commute;
 }
 
 void smpi_op_destroy(MPI_Op op)