Blame SOURCES/bz1769784-fencing-improve-stdin-quote-parsing.patch

97bc7e
From 82626dbdb12519e95a5df70ae6ae21bc17112f43 Mon Sep 17 00:00:00 2001
97bc7e
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
97bc7e
Date: Wed, 13 Feb 2019 13:28:25 +0100
97bc7e
Subject: [PATCH] fencing: improve stdin parse function
97bc7e
97bc7e
- Remove quotes around stdin parameters for consistency with CLI
97bc7e
parameters and to be able to quote number and time parameters
97bc7e
---
97bc7e
 lib/fencing.py.py | 1 +
97bc7e
 1 file changed, 1 insertion(+)
97bc7e
97bc7e
diff --git a/lib/fencing.py.py b/lib/fencing.py.py
97bc7e
index 287cd01f..8cd0a813 100644
97bc7e
--- a/lib/fencing.py.py
97bc7e
+++ b/lib/fencing.py.py
97bc7e
@@ -1389,6 +1389,7 @@ def _parse_input_stdin(avail_opt):
97bc7e
 
97bc7e
 		(name, value) = (line + "=").split("=", 1)
97bc7e
 		value = value[:-1]
97bc7e
+		value = re.sub("^\"(.*)\"$", "\\1", value)
97bc7e
 
97bc7e
 		if name.replace("-", "_") in mapping_longopt_names:
97bc7e
 			name = mapping_longopt_names[name.replace("-", "_")]