From 0bd0c5b9f11add0addb3af8e62aa423995e1722b Mon Sep 17 00:00:00 2001 From: Pingfan Liu Date: Fri, 11 Dec 2020 09:20:00 +0800 Subject: [PATCH] kdumpctl: fix a variable expansion in check_fence_kdump_config() Both $ipaddrs and $node can hold multiple strings, so use "" to brace them. Signed-off-by: Pingfan Liu Acked-by: Kairui Song --- kdumpctl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kdumpctl b/kdumpctl index 3f6a9be..2e7f842 100755 --- a/kdumpctl +++ b/kdumpctl @@ -944,7 +944,7 @@ check_fence_kdump_config() return 1 fi # node can be ipaddr - echo $ipaddrs | grep $node > /dev/null + echo "$ipaddrs " | grep "$node " > /dev/null if [ $? -eq 0 ]; then derror "Option fence_kdump_nodes cannot contain $node" return 1