Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
do not free the group of MPI_COMM_WORLD when asked, because it is a global in smpi...
authorAugustin Degomme <degomme@idpann.imag.fr>
Tue, 23 Oct 2012 08:13:47 +0000 (10:13 +0200)
committerAugustin Degomme <degomme@idpann.imag.fr>
Tue, 23 Oct 2012 17:07:38 +0000 (19:07 +0200)
src/smpi/smpi_pmpi.c

index 8baedae..d34903c 100644 (file)
@@ -271,6 +271,7 @@ int PMPI_Group_free(MPI_Group * group)
   if (group == NULL) {
     retval = MPI_ERR_ARG;
   } else {
   if (group == NULL) {
     retval = MPI_ERR_ARG;
   } else {
+    if(*group!= smpi_comm_group(MPI_COMM_WORLD))// do not free the group of the comm_world
     smpi_group_destroy(*group);
     *group = MPI_GROUP_NULL;
     retval = MPI_SUCCESS;
     smpi_group_destroy(*group);
     *group = MPI_GROUP_NULL;
     retval = MPI_SUCCESS;