X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/103bca762ad0b1163ff856766caa1e7599a53477..28335d43a1e64d3a412e8d6b86e59a389852b0d1:/teshsuite/smpi/isp/umpire/errhandler-no-free.c diff --git a/teshsuite/smpi/isp/umpire/errhandler-no-free.c b/teshsuite/smpi/isp/umpire/errhandler-no-free.c deleted file mode 100644 index 2d55368276..0000000000 --- a/teshsuite/smpi/isp/umpire/errhandler-no-free.c +++ /dev/null @@ -1,69 +0,0 @@ -/* -*- Mode: C; -*- */ -/* Creator: Bronis R. de Supinski (bronis@llnl.gov) */ - -/* errhandler-no-error.c -- construct some MPI_Errhandlers and free them */ - -#ifndef lint -static char *rcsid = - "$Header: /usr/gapps/asde/cvs-vault/umpire/tests/errhandler-no-free.c,v 1.1 2002/05/29 16:09:48 bronis Exp $"; -#endif - -#include -#include -#include "mpi.h" - -/* multiple instances of same errhandler to exercise more Umpire code... */ -#define ERRHANDLER_COUNT 5 - - - -void -myErrhandler (MPI_Comm *comm, int *errorcode, ...) -{ - char buf[MPI_MAX_ERROR_STRING]; - int error_strlen; - - /* print alert */ - fprintf (stderr, "Caught an MPI Error! Time to abort!\n"); - - /* get and print MPI error message... */ - MPI_Error_string (*(errorcode), buf, &error_strlen); - fprintf (stderr, "%s\n", buf); - - MPI_Abort (*comm, *errorcode); - - return; -} - - -int -main (int argc, char **argv) -{ - int nprocs = -1; - int rank = -1; - MPI_Comm comm = MPI_COMM_WORLD; - int i; - char processor_name[128]; - int namelen = 128; - MPI_Errhandler newerrhandler[ERRHANDLER_COUNT]; - - /* init */ - MPI_Init (&argc, &argv); - MPI_Comm_size (comm, &nprocs); - MPI_Comm_rank (comm, &rank); - MPI_Get_processor_name (processor_name, &namelen); - printf ("(%d) is alive on %s\n", rank, processor_name); - fflush (stdout); - - MPI_Barrier (comm); - - for (i = 0; i < ERRHANDLER_COUNT; i++) - MPI_Errhandler_create (myErrhandler, &newerrhandler[i]); - - MPI_Barrier (comm); - - printf ("(%d) Finished normally\n", rank); - MPI_Finalize (); -} - -/* EOF */