HomeClusterLabs Projects

Fix: libcrmcommon: Detect newly created alerts section

Description

Fix: libcrmcommon: Detect newly created alerts section

This fixes a regression introduced by 20ad1a97.

If the CIB does not already contain an alerts element, creating a new
alert requires creating the alerts element. This is included in the
patchset as a create operation. (Adding a new alert to an existing
alerts element is a modify operation.)

Prior to this commit, we were checking whether cib_op="create". We
should be checking whether operation="create".

As a result, if a new alert was created in a CIB that did not previously
contain an alerts element, the controller would not detect the change
and would not process the new alert.

Fixes T865
Fixes RHEL-55458

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

Details