File Utility Program (FUP) Management Programming Manual

FUP Programmatic Interface
File Utility Program (FUP) Management Programming Manual523322-001
2-17
Handling FUP Errors
If the value of ZSPI-TKN-RESPONSE-TYPE is ZSPI-VAL-ERR-AND-WARN, and a
warning occurs for the command (not caused by the execution of the command on a
file), FUP holds the warning until it generates a response caused by an error or
warning for one of the files. If no warnings or errors are generated for any of the files,
FUP returns the command warning in an empty response.
Handling FUP Errors
If ZSPI-TKN-RETCODE contains a value other than zero, an error or warning
occurred, and the response buffer contains one or more error lists.
Figure 2-7. Contents of an Error List
An error list begins with ZSPI-TKN-ERRLIST and ends with ZSPI-TKN-ENDLIST. The
error token ZSPI-TKN-ERROR, which is always included in the error list, contains the
FUP subsystem ID and the error number. Other tokens in the error list describe
different aspects of the error such as the FUP command number and the file FUP was
processing when the error occurred.
FUP returns a second (and sometimes third) nested error list when the error originates
from another subsystem or software component (such as the FASTSORT utility or the
Guardian file system).
The empty response occurs when ZSPI-TKN-RETCODE contains a value other than
zero and the response buffer does not contain an error list. FUP returns an empty
response when the command buffer contains the context token ZSPI-TKN-CONTEXT,
but no more files remain to process.
If ZSPI-TKN-RETCODE is zero, the response buffer can still contain an error list that
describes a warning condition. The warning condition did not prevent FUP from
performing the requested command. To determine the warning, you must check the
value of the ZSPI-TKN-ERROR token in the error list.
ZSPI-TKN-ERRLIST
ZSPI-TKN-ERROR
token-1
token-2
.
.
.
token-n
nested error list, if another subsystem error occurs
ZSPI-TKN-ENDLIST
Note. For a description of all of the FUP error lists, see Appendix B, FUP Error Messages.
Note. For more information about an empty response, see Tokens in a Single FUP Response
Record on page 2-14.