home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_10_11
/
1011086a
< prev
next >
Wrap
Text File
|
1992-10-05
|
461b
|
24 lines
goto Approach (Ken Pugh's approach)
static int /* status */
general_routine ()
{
int status = STS_OK;
if (<error condition 1>)
{
status = ERROR_CODE_1;
goto label_01;
}
if (<error condition 2>)
{
status = ERROR_CODE_@;
goto label_)01;
}
...
<more error checking>
<finally do something>
label_01:
return (status);
}