petsc-3.12.5 2020-03-29
Report Typos and Errors

SETERRQ1

Macro that is called when an error has been detected,

Synopsis

#include <petscsys.h>
PetscErrorCode SETERRQ1(MPI_Comm comm,PetscErrorCode ierr,char *formatmessage,arg)
Collective

Input Parameters

comm - A communicator, so that the error can be collective
ierr - nonzero error code, see the list of standard error codes in include/petscerror.h
message - error message in the printf format
arg - argument (for example an integer, string or double)

Notes

Once the error handler is called the calling function is then returned from with the given error code.

Experienced users can set the error handler with PetscPushErrorHandler().

See Also

PetscTraceBackErrorHandler(), PetscPushErrorHandler(), PetscError(), CHKERRQ(), CHKMEMQ, SETERRQ(), SETERRQ2(), SETERRQ3()

Level

beginner

Location

src/sys/error/../../../include/petscerror.h

Examples

src/sys/classes/random/examples/tutorials/ex2.c.html
src/dm/examples/tutorials/swarm_ex1.c.html
src/dm/examples/tutorials/swarm_ex3.c.html
src/dm/field/examples/tutorials/ex1.c.html
src/ksp/ksp/examples/tutorials/ex42.c.html
src/ksp/ksp/examples/tutorials/ex56.c.html
src/ksp/ksp/examples/tutorials/ex59.c.html
src/ksp/ksp/examples/tutorials/ex70.c.html
src/ksp/ksp/examples/tutorials/ex71.c.html
src/ksp/ksp/examples/tutorials/ex74.c.html
src/snes/examples/tutorials/ex5.c.html

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages