X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/bc75e22e7ea7c0fdc45e5622d8f95b90bdcf2c27..b382315f0693083344eb9a25a8fc37b7091bddc7:/teshsuite/smpi/mpich3-test/info/infotest.c diff --git a/teshsuite/smpi/mpich3-test/info/infotest.c b/teshsuite/smpi/mpich3-test/info/infotest.c index 1ce76ae674..4e73cafa9f 100644 --- a/teshsuite/smpi/mpich3-test/info/infotest.c +++ b/teshsuite/smpi/mpich3-test/info/infotest.c @@ -13,44 +13,44 @@ #include #endif -int main( int argc, char *argv[] ) +int main(int argc, char *argv[]) { MPI_Info i1, i2; int errs = 0; char value[64]; int flag; - MPI_Init( &argc, &argv ); - - MPI_Info_create( &i1 ); - MPI_Info_create( &i2 ); + MPI_Init(&argc, &argv); - MPI_Info_set( i1, (char*)"key1", (char*)"value1" ); - MPI_Info_set( i2, (char*)"key2", (char*)"value2" ); + MPI_Info_create(&i1); + MPI_Info_create(&i2); - MPI_Info_get( i1, (char*)"key2", 64, value, &flag ); + MPI_Info_set(i1, (char *) "key1", (char *) "value1"); + MPI_Info_set(i2, (char *) "key2", (char *) "value2"); + + MPI_Info_get(i1, (char *) "key2", 64, value, &flag); if (flag) { - printf( "Found key2 in info1\n" ); - errs ++; + printf("Found key2 in info1\n"); + errs++; } - MPI_Info_get( i1, (char*)"key1", 64, value, &flag ); + MPI_Info_get(i1, (char *) "key1", 64, value, &flag); if (!flag) { - errs++; - printf( "Did not find key1 in info1\n" ); + errs++; + printf("Did not find key1 in info1\n"); } - else if (strcmp( value, "value1" )) { - errs++; - printf( "Found wrong value (%s), expected value1\n", value ); + else if (strcmp(value, "value1")) { + errs++; + printf("Found wrong value (%s), expected value1\n", value); } - MPI_Info_free( &i1 ); - MPI_Info_free( &i2 ); + MPI_Info_free(&i1); + MPI_Info_free(&i2); if (errs) { - printf( " Found %d errors\n", errs ); + printf(" Found %d errors\n", errs); } else { - printf( " No Errors\n" ); + printf(" No Errors\n"); } - MPI_Finalize( ); + MPI_Finalize(); return 0; }