Catch

Syntax

int Catch(lpCatchBuf)

This function catches the current execution environment and copies it to the buffer pointed to by the lpCatchBuf parameter. The execution environment is the state of all system registers and the instruction counter.

Parameter Type/Description  

lpCatchBuf LPCATCHBUF Points to the CATCHBUF structure that will receive the execution environment.  

Return Value

The return value specifies whether the execution environment is copied to the buffer. It is zero if the environment is copied to the buffer.

Comments

The Throw function uses the buffer to restore the execution environment to its previous values.

The Catch function is similar to the C run-time setjmp function (which is incompatible with the Windows environment).