ShellCheck - shell script analysis tool version: 0.10.0 license: GNU General Public License, version 3 website: https://www.shellcheck.net Redirect to /tmp/tmp.0zWHSzNrNm and /tmp/tmp.Z13ISv7rZu Tree base: df94e2c679c0 ("selftest: packetdrill: Require explicit setsockopt(TCP_FASTOPEN).") Now at: 1097cd486ddc ("selftest: packetdrill: Define common TCP Fast Open cookie.") ====== Checking before the patch ====== Checking tools/testing/selftests/net/packetdrill/defaults.sh - b2c91db8e0d15129183a90fe2c5a0db496bcef2c54630406ba897941960925cb Checking tools/testing/selftests/net/packetdrill/ksft_runner.sh - b44cd6648b9af340281c0bfcfb2e337aafc4c3a7aa9537ed45e0c14d4634b280 In ksft_runner.sh line 4: source "$(dirname $(realpath $0))/../../kselftest/ktap_helpers.sh" ^------------^ SC2046 (warning): Quote this to prevent word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: source "$(dirname $(realpath "$0"))/../../kselftest/ktap_helpers.sh" In ksft_runner.sh line 27: script="$(basename $1)" ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: script="$(basename "$1")" In ksft_runner.sh line 42: ip_versions=$(grep -E '^--ip_version=' $script | cut -d '=' -f 2) ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip_versions=$(grep -E '^--ip_version=' "$script" | cut -d '=' -f 2) In ksft_runner.sh line 54: unshare -n packetdrill ${ip_args[$ip_version]} ${optargs[@]} $script > /dev/null \ ^---------------------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-----------^ SC2068 (error): Double quote array expansions to avoid re-splitting elements. ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: unshare -n packetdrill "${ip_args[$ip_version]}" ${optargs[@]} "$script" > /dev/null \ In ksft_runner.sh line 55: && ktap_test_pass $ip_version || $failfunc $ip_version ^-- SC2015 (info): Note that A && B || C is not if-then-else. C may run when A is true. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: && ktap_test_pass "$ip_version" || $failfunc "$ip_version" For more information: https://www.shellcheck.net/wiki/SC2068 -- Double quote array expansions to ... https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt... https://www.shellcheck.net/wiki/SC2015 -- Note that A && B || C is not if-t... ====== Checking the tree with the patch ====== Checking tools/testing/selftests/net/packetdrill/defaults.sh - b2c91db8e0d15129183a90fe2c5a0db496bcef2c54630406ba897941960925cb Checking tools/testing/selftests/net/packetdrill/ksft_runner.sh - b44cd6648b9af340281c0bfcfb2e337aafc4c3a7aa9537ed45e0c14d4634b280 In ksft_runner.sh line 4: source "$(dirname $(realpath $0))/../../kselftest/ktap_helpers.sh" ^------------^ SC2046 (warning): Quote this to prevent word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: source "$(dirname $(realpath "$0"))/../../kselftest/ktap_helpers.sh" In ksft_runner.sh line 29: script="$(basename $1)" ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: script="$(basename "$1")" In ksft_runner.sh line 44: ip_versions=$(grep -E '^--ip_version=' $script | cut -d '=' -f 2) ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip_versions=$(grep -E '^--ip_version=' "$script" | cut -d '=' -f 2) In ksft_runner.sh line 56: unshare -n packetdrill ${ip_args[$ip_version]} ${optargs[@]} $script > /dev/null \ ^---------------------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-----------^ SC2068 (error): Double quote array expansions to avoid re-splitting elements. ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: unshare -n packetdrill "${ip_args[$ip_version]}" ${optargs[@]} "$script" > /dev/null \ In ksft_runner.sh line 57: && ktap_test_pass $ip_version || $failfunc $ip_version ^-- SC2015 (info): Note that A && B || C is not if-then-else. C may run when A is true. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: && ktap_test_pass "$ip_version" || $failfunc "$ip_version" For more information: https://www.shellcheck.net/wiki/SC2068 -- Double quote array expansions to ... https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt... https://www.shellcheck.net/wiki/SC2015 -- Note that A && B || C is not if-t... tools/testing/selftests/net/packetdrill/defaults.sh is shellcheck compliant