#include <setjmp.h>
int setjmp(jmp_buf env);
setjmp() saves the current program state in the environment buffer env and returns zero. This buffer can be used as a parameter to a later call to longjmp(), which then restores the program state and jumps back to the location of the setjmp. This time, setjmp() returns a non-zero value, which is equal to the second parameter to longjmp().
Zero if called directly; non-zero if called by a longjmp().