18.2.170. PMIx_Regattr_destruct

PMIx_Regattr_destruct — Release the contents of a pmix_regattr_t(5) structure.

18.2.170.1. SYNOPSIS

#include <pmix.h>

void PMIx_Regattr_destruct(pmix_regattr_t *p);

18.2.170.1.1. Python Syntax

No Python equivalent

18.2.170.2. INPUT PARAMETERS

18.2.170.3. DESCRIPTION

Release the dynamically allocated contents of a pmix_regattr_t structure. The function frees the name string (if present) and frees the description string array (if present), resetting both pointers to NULL. The fixed-size string key and the type field require no separate release.

PMIx_Regattr_destruct releases only the payload the structure references; it does not free the storage of the pmix_regattr_t structure itself. It is therefore the correct counterpart to PMIx_Regattr_construct(3) for structures whose storage was supplied by the caller (stack or embedded).

If p is NULL, the function does nothing.

18.2.170.4. RETURN VALUE

PMIx_Regattr_destruct returns no value (void).

18.2.170.5. NOTES

The PMIX_REGATTR_DESTRUCT convenience macro is a direct wrapper for this function.

To release an array of registration-attribute structures allocated by PMIx_Regattr_create(3) — including the array storage itself — use PMIx_Regattr_free(3) instead.