FCHECK [ KSAM/3000 Reference Manual ] MPE/iX 5.0 Documentation
KSAM/3000 Reference Manual
FCHECK
INTRINSIC NUMBER 10
Requests details about file input/output errors.
IV I I D I O-V
FCHECK(filenum,errorcode,tlog,blknum,numrecs);
When a file intrinsic returns a condition code indicating a physical
input/output error, additional details may be obtained by calling FCHECK.
This intrinsic applies to files on any device.
FCHECK accepts zero as a legal filenum parameter value. When zero is
specified, the information returned in errorcode reflects the status of
the last call to FOPEN. When an FOPEN fails, there is no file number that
can be referenced in filenum. Therefore, when an FOPEN fails, a filenum
of zero can be used in the FCHECK intrinsic call to obtain the errorcode
only. If the tlog, blknum, or numrecs parameters are specified, a zero
value is returned to these parameters. If a filenum of zero is used for
a file which has been opened but not yet closed, the returned errorcode
is meaningless.
PARAMETERS
filenum integer by value (required)
A word identifier supplying the file number of the file
for which error information is to be returned.
errorcode integer (optional)
A word to which is returned the error code specifying
the type of error that occurred. If no error occurred
errorcode is set to zero. (Refer to Table 4-3 for the
errorcode values.) The intrinsic FERRMSG returns a
displayable message that corresponds to the value of
errorcode.
Default: The error code is not returned.
tlog integer (optional)
A word to which is returned the transmission log value
recorded when an erroneous data transfer occurs. This
word specifies the number of words not read or written
(those left over) as the result of an input/ output
error.
Default: The transmission log value is not returned.
blknum double (optional)
A double word to which is returned the relative number
of the block involved in the error.
Default: The block number is not returned.
numrecs integer (optional)
A word to which is returned the number of logical
records in the bad block.
Default: The number of logical records is not returned.
CONDITION CODES
CCE Request granted.
CCG Not returned by this intrinsic.
CCL Request denied because filenum was invalid and errorcode
is 72, or a bounds violation occurred while processing
this request and errorcode is 73.
SPECIAL CONSIDERATIONS
Split stack calls permitted.
Table 4-3. FCHECK errorcode Parameter Format
Table 4-3. FCHECK errorcode Parameter Format (continued)
Table 4-3. FCHECK errorcode Parameter Format (continued)
Table 4-3. FCHECK errorcode Parameter Format (continued)
MPE/iX 5.0 Documentation