Performing ``Non-Local'' Goto

In many situations, you may want to jump to a location that is very far away from the current function. Sometimes, the destination is even not in the same function. For example, when a signal occurs, the program logic may require the control flow be sent to a very special function after the signal is handled. In this case, some addition mechanism is required to perform this type of non-local gotos. This is the job of header file setjmp.h and functions setjmp() and longjmp().

To perform non-local gotos, you need to do the following:

But, You Need to Know More ......

You need to know more before start writing programs with non-local gotos: