
Appendix B. REXX utility procedures 347
Final_Exit:
Parse Arg final_rc
If sig_enabled Then
Call Syscall_Cmd "sigaction" sigalrm ohdl oflg "x y",,
noexit_on_error
Call Syscalls "SIGOFF"
Do i=0 To 2
If fd.i<>-1 Then Call Syscall_Cmd "close (fd.i)", noexit_on_error
End
If pp.1<>-1 Then Call Syscall_Cmd "close (pp.1)", noexit_on_error
Exit final_rc
Syscall_Cmd:
Parse Arg syscall_cmd, call_type, no_display
display_msgs = (no_display<>"1")
exit_on_error = (call_type="")
Address SYSCALL syscall_cmd
not_OK = (rc<>0 | retval<0 | retval=0 & (errno<>0 | errnojr<>0))
OK = (not_OK = 0)
If not_OK & display_msgs Then Do
If call_type=info_on_timeout & errno=78 ...