File bsc#1171372-0009-Fix-libstonithd-respect-pcmk_host_argument-none-on-v.patch of Package pacemaker.26926

From acb8c0c16261af6a5ddaeb06b39d803872094d0d Mon Sep 17 00:00:00 2001
From: "Gao,Yan" <ygao@suse.com>
Date: Fri, 8 May 2020 01:25:56 +0200
Subject: [PATCH] Fix: libstonithd: respect `pcmk_host_argument=none` on
 `validate`

Although for now by default, `port` is still added in make_args() for
backward compatibility. This will be really respected in the future
possibly since 2.1.0.
---
 lib/fencing/st_rhcs.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/fencing/st_rhcs.c b/lib/fencing/st_rhcs.c
index 1c9b614f3..160f15bf9 100644
--- a/lib/fencing/st_rhcs.c
+++ b/lib/fencing/st_rhcs.c
@@ -272,6 +272,9 @@ stonith__rhcs_validate(stonith_t *st, int call_options, const char *target,
         if (rc == -ETIME || remaining_timeout <= 0 ) {
             return -ETIME;
         }
+
+    } else if (safe_str_eq(host_arg, "none")) {
+        host_arg = NULL;
     }
 
     action = stonith_action_create(agent, "validate-all",
-- 
2.26.1

openSUSE Build Service is sponsored by