rlcha: Release chained file records
This function releases chained pool record addresses from the record first specified through the end of chain using standard z/TPF record headers. The input argument hdr may point at any standard header. The record ID and the record code check for all records in the chain must match the header pointed to by hdr.
Last updated
- Changed for PUT05.
- Changed for PUT03.
Format
#include <tpf/tpfapi.h>
void rlcha(struct stdhdr *hdr);or
#include <tpf/tpfapi.h>
#include <tpf/c_std8.h>
void rlcha(struct istd8 *hdr); - hdr
- This argument is a pointer to struct stdhdr (see tpfapi.h) or struct istd8 (see c_std8.h), which describe the z/TPF standard record header.
Normal return
Void.
Error return
Not applicable.
Programming considerations
- To be released, all succeeding records must have the same record ID and code check as the first record in the chain. If the succeeding records do not have the same ID and code check, the RLCH or CLC8 program exits.
- If a queue for the rlcha request does not exist or if the queue is full, this function issues a cremc function to the RLCH or CLC8 program. The cremc function can cause depletion of storage.
- z/TPF transaction services processing
affects rlcha processing
in the following ways:
- Delay issuing the rlcha function until commit processing has completed successfully.
- When rollback occurs, rlcha function requests are discarded and the file addresses are not released.
- Applications that call this function using the struct istd8 interface must be compiled with the C++ compiler because this function has been overloaded.
- This function is implemented in the CTAD library.
- Multiple release detection (MRD) is processed asynchronously for rlcha requests.
Examples
The following example starts the release
of the chain of pool record addresses beginning with the address found in
the standard header on level D5.
#include <tpf/tpfapi.h>
struct stdhdr *cp0hdr;
⋮
cp0hdr = ecbptr()->ce1cr5;
rlcha(cp0hdr);The following example starts the release
of the chain of pool record addresses beginning with the address found in
the 8-byte standard header on the DECB pointed
to by decb_ptr.
#include <tpf/tpfapi.h>
#include <tpf/tpf/c_std8.h>
#include <tpf/i_decb.h>
TPF_DECB *decb_ptr;
DECBC_RC rc;
struct istd8* block_header
decb_ptr = tpf_decb_create( NULL, &rc );
⋮
block_header = (istd8 *)decb_ptr->idecdad;
rlcha( block_header );Related information
See the z/TPF Database User's Guide for more information about MRD.
See z/TPF C functions overview for more information about z/TPF C/C++ language support.