SC2086 Double quote to prevent globbing and word splitting.
Apparently ShellCheck is more picky about some of these than it used
to be.
Signed-off-by: Martin Schwenke <mschwenke@ddn.com>
Reviewed-by: Andreas Schneider <asn@samba.org>
else
setup_public_addresses "$_num_nodes" \
$_node_no_ips \
- $_use_ipv6 >"$_public_addresses_all"
+ "$_use_ipv6" >"$_public_addresses_all"
fi
_cluster_lock_dir="${directory}/shared/.ctdb"
_public_addresses="${CTDB_BASE}/public_addresses"
if [ -z "$_public_addresses_file" ] && \
- [ $_node_no_ips -eq "$_n" ] ; then
+ [ "$_node_no_ips" -eq "$_n" ] ; then
echo "Node ${_n} will have no public IPs."
: >"$_public_addresses"
else
die "test \"$f\" is not recognised"
fi
- if $exit_on_fail && [ $status -ne 0 ] ; then
- return $status
+ if $exit_on_fail && [ "$status" -ne 0 ] ; then
+ return "$status"
fi
done
}
done
if $with_summary ; then
- if [ $status -eq 0 ] || ! $exit_on_fail ; then
+ if [ "$status" -eq 0 ] || ! $exit_on_fail ; then
echo
cat "$summary_file"
do_cleanup
if $no_header || $exit_on_fail ; then
- exit $status
+ exit "$status"
elif [ $tests_failed -gt 0 ] ; then
exit 1
else