[Drbd-dev] [PATCH 5/6] crm-fence-peer.sh: Modify empty string assignment statements

Bart Van Assche bart.vanassche at sandisk.com
Tue Jun 14 13:57:45 CEST 2016


This patch does not change any functionality but avoids that
shellcheck reports the following warning:

  warning: Remove space after = if trying to assign a value (for empty string, use var='' ... ). [SC1007]

Signed-off-by: Bart Van Assche <bart.vanassche at sandisk.com>
---
 scripts/crm-fence-peer.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/scripts/crm-fence-peer.sh b/scripts/crm-fence-peer.sh
index 1eac65a..bc67259 100755
--- a/scripts/crm-fence-peer.sh
+++ b/scripts/crm-fence-peer.sh
@@ -488,7 +488,7 @@ guess_if_pacemaker_will_fence()
 	local x
 
 	# "return values:"
-	crmd= in_ccm= expected= join= will_fence=false
+	crmd='' in_ccm='' expected='' join='' will_fence=false
 
 	# Older pacemaker has an "ha" attribute, too.
 	# For stonith-enabled=false, the "crmd" attribute may stay "online",
@@ -573,8 +573,8 @@ check_peer_node_reachable()
 	nr_other_nodes=$#
 
 	while :; do
-		local state_lines= node_state=
-		local crmd= in_ccm= expected= join= will_fence= ha_dead=
+		local state_lines='' node_state='' crmd='' in_ccm=''
+		local expected='' join='' will_fence='' ha_dead=''
 
 		while :; do
 			local t=$SECONDS
-- 
2.8.4



More information about the drbd-dev mailing list