HomeClusterLabs Projects

API: libcrmcluster: New pcmk_cluster_new() and pcmk_cluster_free()

This commit no longer exists in the repository. It may have been part of a branch which was deleted.

Description

API: libcrmcluster: New pcmk_cluster_new() and pcmk_cluster_free()

pcmk_cluster_new() is a simple constructor that allocates a
crm_cluster_t object and asserts non-NULL. The use of a constructor
function will enable extending crm_cluster_t in the future.

pcmk_cluster_free() safely frees a crm_cluster_t object and its
dynamically allocated members.

These will likely be a part of the improvements for T598. That task may
also require functionizing freeing the members of crm_cluster_t, since
there's at least one place where crm_cluster_t is statically allocated
but its members are dynamically allocated.

Ref T598

Signed-off-by: Reid Wahl <nrwahl@protonmail.com>

Details

Provenance
nrwahl2Authored on Nov 24 2022, 5:08 PM
Tasks
Restricted Maniphest Task

Commit No Longer Exists

This commit no longer exists in the repository.