HomeClusterLabs Projects

Fix: libcrmcluster: Ensure priv is non-NULL in crm_cluster_connect()

Description

Fix: libcrmcluster: Ensure priv is non-NULL in crm_cluster_connect()

sbd doesn't call the constructor (pcmk_cluster_new()) to create the
pcmk_cluster_t object, as it should. Instead, it uses a static object.
As a result, the priv member has not been allocated when sbd calls
crm_cluster_connect().

Fixes regression (for sbd) introduced in f0df6261. Callers that use the
pcmk_cluster_new() constructor were unaffected. This regression did not
make it into any release.

Reported by gao-yan

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

Details

Provenance
nrwahl2Authored on Jun 28 2024, 5:09 PM
Parents
rP24554aa21186: Merge pull request #3539 from nrwahl2/nrwahl2-compat_drops
Branches
Unknown
Tags
Unknown