Standards / Extensions | C or C++ | Dependencies |
---|---|---|
C Library | both |
#include <dynit.h>
int dynfree(__dyn_t *dyn_parms);
Dynamically deallocates a z/OS data set in accordance with the attributes defined in dyn_parms.
To avoid infringing on the user's name space, this nonstandard function has two names. One name is prefixed with two underscore characters, and one name is not. The name without the prefix underscore characters is exposed only when you use LANGLVL(EXTENDED).
To use this function, you must either invoke the function using its external entry point name (that is, the name that begins with two underscore characters), or compile with LANGLVL(EXTENDED). When you use LANGLVL(EXTENDED) any relevant information in the header is also exposed.
If any other fields are specified, they will be ignored. For more information on the __dyn_t structure, see Table 1
If successful under z/OS, dynfree() returns 0.
If unsuccessful, dynfree() returns nonzero. dynfree() returns -1 if there is not sufficient storage to process all the text units.
/*
This example dynamically deallocates a data set.
*/
#include <dynit.h>
int main(void) {
⋮
__dyn_t ip;
⋮
dyninit(ip);
ip.__ddname = "mydd";
⋮
dynfree(&ip);
}