File bsc#1206263-0004-Fix-libpacemaker-ensure-any-pending-recurring-monito.patch of Package pacemaker.27560

From 11689380bb663bde3699093248039aa9479082f5 Mon Sep 17 00:00:00 2001
From: "Gao,Yan" <ygao@suse.com>
Date: Mon, 5 Dec 2022 15:13:18 +0100
Subject: [PATCH 4/6] Fix: libpacemaker: ensure any pending recurring monitor
 gets updated if it fails

So that it prevents any pending recurring monitor from getting stuck in
the CIB status.
---
 lib/common/operations.c | 4 ++++
 1 file changed, 4 insertions(+)

Index: pacemaker-1.1.24+20210811.f5abda0ee/lib/common/operations.c
===================================================================
--- pacemaker-1.1.24+20210811.f5abda0ee.orig/lib/common/operations.c
+++ pacemaker-1.1.24+20210811.f5abda0ee/lib/common/operations.c
@@ -544,6 +544,10 @@ create_operation_update(xmlNode * parent
         if (op->interval == 0) {
             /* Ensure 'last' gets updated too in case recording-pending="true" */
             op_id_additional = generate_op_key(op->rsc_id, "last", 0);
+
+        } else {
+            // Ensure any pending recurring monitor gets updated if it fails
+            op_id_additional = strdup(key);
         }
         exit_reason = op->exit_reason;
 
openSUSE Build Service is sponsored by