ShellCheck - shell script analysis tool version: 0.11.0 license: GNU General Public License, version 3 website: https://www.shellcheck.net Redirect to /tmp/tmp.j3igE1FbYb and /tmp/tmp.rHpuYxfWKe Tree base: 3ff545e22141 ("netfilter: nft_connlimit: add support to object update operation") Now at: d466f57e7390 ("selftests: netfilter: nft_flowtable.sh: Add the capability to send IPv6 TCP traffic") ====== Checking before the patch ====== Checking tools/testing/selftests/net/netfilter/nft_flowtable.sh - 97ed1c3a9028e5fbabf61c0ddfacbdf11133e6f66732fb13ef0c6fb42b70b4aa In nft_flowtable.sh line 34: cleanup() { ^-- SC2329 (info): This function is never invoked. Check usage (or ignored if invoked indirectly). In nft_flowtable.sh line 35: ip netns pids "$ns1" | xargs kill 2>/dev/null ^--^ SC2154 (warning): ns1 is referenced but not assigned. In nft_flowtable.sh line 36: ip netns pids "$ns2" | xargs kill 2>/dev/null ^--^ SC2154 (warning): ns2 is referenced but not assigned. In nft_flowtable.sh line 49: ip link add veth0 netns "$nsr1" type veth peer name eth0 netns "$ns1" ^---^ SC2154 (warning): nsr1 is referenced but not assigned. In nft_flowtable.sh line 50: ip link add veth1 netns "$nsr1" type veth peer name veth0 netns "$nsr2" ^---^ SC2154 (warning): nsr2 is referenced but not assigned. In nft_flowtable.sh line 185: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In nft_flowtable.sh line 205: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In nft_flowtable.sh line 274: local pmtud="$2" ^---^ SC2034 (warning): pmtud appears unused. Verify use (or export if used externally). In nft_flowtable.sh line 345: listener_ready() ^-- SC2329 (info): This function is never invoked. Check usage (or ignored if invoked indirectly). In nft_flowtable.sh line 362: if [ $pmtu -eq 0 ]; then ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$pmtu" -eq 0 ]; then In nft_flowtable.sh line 378: rc=1 ^-- SC2034 (warning): rc appears unused. Verify use (or export if used externally). In nft_flowtable.sh line 415: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In nft_flowtable.sh line 432: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. For more information: https://www.shellcheck.net/wiki/SC2034 -- pmtud appears unused. Verify use ... https://www.shellcheck.net/wiki/SC2154 -- ns1 is referenced but not assigned. https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ... ====== Checking the tree with the patch ====== Checking tools/testing/selftests/net/netfilter/nft_flowtable.sh - 97ed1c3a9028e5fbabf61c0ddfacbdf11133e6f66732fb13ef0c6fb42b70b4aa In nft_flowtable.sh line 34: cleanup() { ^-- SC2329 (info): This function is never invoked. Check usage (or ignored if invoked indirectly). In nft_flowtable.sh line 35: ip netns pids "$ns1" | xargs kill 2>/dev/null ^--^ SC2154 (warning): ns1 is referenced but not assigned. In nft_flowtable.sh line 36: ip netns pids "$ns2" | xargs kill 2>/dev/null ^--^ SC2154 (warning): ns2 is referenced but not assigned. In nft_flowtable.sh line 49: ip link add veth0 netns "$nsr1" type veth peer name eth0 netns "$ns1" ^---^ SC2154 (warning): nsr1 is referenced but not assigned. In nft_flowtable.sh line 50: ip link add veth1 netns "$nsr1" type veth peer name veth0 netns "$nsr2" ^---^ SC2154 (warning): nsr2 is referenced but not assigned. In nft_flowtable.sh line 189: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In nft_flowtable.sh line 209: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In nft_flowtable.sh line 278: local pmtud="$2" ^---^ SC2034 (warning): pmtud appears unused. Verify use (or export if used externally). In nft_flowtable.sh line 349: listener_ready() ^-- SC2329 (info): This function is never invoked. Check usage (or ignored if invoked indirectly). In nft_flowtable.sh line 367: if [ $pmtu -eq 0 ]; then ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$pmtu" -eq 0 ]; then In nft_flowtable.sh line 371: timeout "$SOCAT_TIMEOUT" ip netns exec "$nsb" socat -${proto} \ ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: timeout "$SOCAT_TIMEOUT" ip netns exec "$nsb" socat -"${proto}" \ In nft_flowtable.sh line 377: timeout "$SOCAT_TIMEOUT" ip netns exec "$nsa" socat -${proto} \ ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: timeout "$SOCAT_TIMEOUT" ip netns exec "$nsa" socat -"${proto}" \ In nft_flowtable.sh line 385: rc=1 ^-- SC2034 (warning): rc appears unused. Verify use (or export if used externally). In nft_flowtable.sh line 428: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In nft_flowtable.sh line 445: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. For more information: https://www.shellcheck.net/wiki/SC2034 -- pmtud appears unused. Verify use ... https://www.shellcheck.net/wiki/SC2154 -- ns1 is referenced but not assigned. https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...