Standard error functions

The z/TPF system provides several C functions that can be used for standard error processing by an application program. They are:
  • serrc_op
  • serrc_op_ext
  • snapc
All of these functions can be used to generate a main storage dump. The snapc, serrc_op, and serrc_op_ext functions determine whether, after dump processing, the ECB is to be exited or the control returned to the application program. It is an application's responsibility to test the I/O indicators in the ECB (ce1sug) to determine the nature of the abnormality and specify the action to be taken.
The serrc_op function enables an application to:
  • Force the ECB to exit, or not
  • Associate a specific system error identification number with the generated dump
  • Send a specified message to the CRAS console
  • Display additional main storage areas on the generated dump.

In addition to the serrc_op capabilities, the serrc_op_ext function enables an application to associate a particular prefix with a system error identification number to determine which user application generated the dump or whether it was an IBM® program that generated the dump.

The snapc function allows an application to:
  • Determine the action to be taken
  • Determine the error number
  • Include the registers in a snapshot dump to the system console
  • Specify the program name that is issuing the snapc function
  • Specify the error message text to be appended to the snapshot dump
  • Specify if the subsystem (SS), subsystem user (SSU) and terminal address should be taken from the ECB
  • Specify the location of the snapc_list struct which indicates the locations and lengths of the areas to be dumped.
  • Indicate the prefix to be put on the identification code for the snapshot dump.