Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
update collectives teshsuite from mpich git (only minor changes)
[simgrid.git] / teshsuite / smpi / mpich3-test / coll / bcastzerotype.c
index 9ebf1f7..59f2a5b 100644 (file)
@@ -1,3 +1,10 @@
+/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */
+/*
+ *
+ *  (C) 2012 by Argonne National Laboratory.
+ *      See COPYRIGHT in top-level directory.
+ */
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <assert.h>
@@ -10,7 +17,7 @@ int main(int argc, char *argv[])
 {
     int i, type_size;
     MPI_Datatype type = MPI_DATATYPE_NULL;
-    int *buf = NULL;
+    char *buf = NULL;
     int wrank, wsize;
 
     MPI_Init(&argc, &argv);
@@ -20,7 +27,7 @@ int main(int argc, char *argv[])
     /* a random non-zero sized buffer */
 #define NELEM (10)
     buf = malloc(NELEM*sizeof(int));
-    assert(buf!=NULL);
+    assert(buf);
 
     for (i = 0; i < NELEM; i++) {
         buf[i] = wrank * NELEM + i;