Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' into master
[simgrid.git] / teshsuite / smpi / isp / umpire / wait-deadlock.c
index 67acdc0..288be7c 100644 (file)
@@ -26,7 +26,6 @@ main (int argc, char **argv)
   MPI_Get_processor_name (processor_name, &namelen);
   printf ("(%d) is alive on %s\n", rank, processor_name);
   fflush (stdout);
-       int i;
   MPI_Barrier (MPI_COMM_WORLD);
 
   if (nprocs < 2)
@@ -35,7 +34,7 @@ main (int argc, char **argv)
     }
   else if (rank == 0)
     {
-      memset (buf0, 0, buf_size);
+      memset (buf0, 0, buf_size*sizeof(int));
 
       MPI_Irecv (buf1, buf_size, MPI_INT, 1, 0, MPI_COMM_WORLD, &req);
 
@@ -45,7 +44,7 @@ main (int argc, char **argv)
     }
   else if (rank == 1)
     {
-      memset (buf1, 1, buf_size);
+      memset (buf1, 1, buf_size*sizeof(int));
 
       MPI_Irecv (buf0, buf_size, MPI_INT, 0, 0, MPI_COMM_WORLD, &req);