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.Gm1qObbisJ and /tmp/tmp.8mE2uPzcuU Tree base: 62777c8015f3 ("Merge branch 'net-stmmac-rk-simplify-per-soc-configuration'") Now at: aeff2c348448 ("selftests: net: fib_tests: skip rp_filter test if cls_basic is unavailable") ====== Checking before the patch ====== Checking tools/testing/selftests/net/fib_tests.sh - 5cf2caf193ae0cd81b3c03740b5c0880a5f8fe5f1415d2463767ec3c2cb2bf69 In fib_tests.sh line 29: if [ ${rc} -eq ${expected} ]; then ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "${rc}" -eq "${expected}" ]; then In fib_tests.sh line 39: read a ^--^ SC2162 (info): read without -r will mangle backslashes. In fib_tests.sh line 47: read a ^--^ SC2162 (info): read without -r will mangle backslashes. In fib_tests.sh line 56: IP="$(which ip) -netns $ns1" ^--^ SC2154 (warning): ns1 is referenced but not assigned. In fib_tests.sh line 58: ip netns exec $ns1 sysctl -qw net.ipv4.ip_forward=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" sysctl -qw net.ipv4.ip_forward=1 In fib_tests.sh line 59: ip netns exec $ns1 sysctl -qw net.ipv6.conf.all.forwarding=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" sysctl -qw net.ipv6.conf.all.forwarding=1 In fib_tests.sh line 72: cleanup_ns $ns1 $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2154 (warning): ns2 is referenced but not assigned. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: cleanup_ns "$ns1" "$ns2" In fib_tests.sh line 80: addr=$($IP -6 -br addr show dev ${dev} | \ ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: addr=$($IP -6 -br addr show dev "${dev}" | \ In fib_tests.sh line 92: echo $addr ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: echo "$addr" In fib_tests.sh line 212: oif $down_dev &> /dev/null ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$down_dev" &> /dev/null In fib_tests.sh line 215: oif $down_dev &> /dev/null ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$down_dev" &> /dev/null In fib_tests.sh line 219: oif $up_dev &> /dev/null ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$up_dev" &> /dev/null In fib_tests.sh line 222: oif $up_dev &> /dev/null ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$up_dev" &> /dev/null In fib_tests.sh line 226: grep $down_dev | grep -q "dead linkdown" ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$down_dev" | grep -q "dead linkdown" In fib_tests.sh line 229: grep $down_dev | grep -q "dead linkdown" ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$down_dev" | grep -q "dead linkdown" In fib_tests.sh line 233: grep $up_dev | grep -q "dead linkdown" ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$up_dev" | grep -q "dead linkdown" In fib_tests.sh line 236: grep $up_dev | grep -q "dead linkdown" ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$up_dev" | grep -q "dead linkdown" In fib_tests.sh line 450: $IP link set dev veth2 netns $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP link set dev veth2 netns "$ns2" In fib_tests.sh line 452: ip -netns $ns2 address add 192.0.2.1/24 dev veth2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" address add 192.0.2.1/24 dev veth2 In fib_tests.sh line 454: ip -netns $ns2 link set dev veth2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev veth2 up In fib_tests.sh line 458: ip -netns $ns2 link set dev lo address 52:54:00:6a:c7:5e ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev lo address 52:54:00:6a:c7:5e In fib_tests.sh line 459: ip -netns $ns2 link set dev veth2 address 52:54:00:6a:c7:5e ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev veth2 address 52:54:00:6a:c7:5e In fib_tests.sh line 462: ip netns exec $ns2 tc qdisc add dev lo parent root handle 1: fq_codel ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc qdisc add dev lo parent root handle 1: fq_codel In fib_tests.sh line 463: ip netns exec $ns2 tc filter add dev lo parent 1: protocol arp basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev lo parent 1: protocol arp basic \ In fib_tests.sh line 465: ip netns exec $ns2 tc filter add dev lo parent 1: protocol ip basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev lo parent 1: protocol ip basic \ In fib_tests.sh line 483: ip netns exec $ns2 tc qdisc add dev veth2 ingress ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc qdisc add dev veth2 ingress In fib_tests.sh line 484: ip netns exec $ns2 tc filter add dev veth2 ingress protocol arp basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev veth2 ingress protocol arp basic \ In fib_tests.sh line 486: ip netns exec $ns2 tc filter add dev veth2 ingress protocol ip basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev veth2 ingress protocol ip basic \ In fib_tests.sh line 492: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.rp_filter=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.rp_filter=1 In fib_tests.sh line 493: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.accept_local=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.accept_local=1 In fib_tests.sh line 494: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.route_localnet=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.route_localnet=1 In fib_tests.sh line 526: printf "\n COMMAND: $cmd\n" ^---------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 529: out=$(eval $cmd 2>&1) ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(eval "$cmd" 2>&1) In fib_tests.sh line 531: if [ "$VERBOSE" = "1" -a -n "$out" ]; then ^-- SC2166 (warning): Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. In fib_tests.sh line 534: log_test $rc $erc "$desc" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: log_test $rc "$erc" "$desc" In fib_tests.sh line 547: local lldummy=$(get_linklocal dummy0) ^-----^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 548: local llv1=$(get_linklocal dummy0) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 567: - 2001:db8:103::1/64 $llv1 "veth0" ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:103::1/64 "$llv1" "veth0" In fib_tests.sh line 571: - 2001:db8:104::1/64 $llv1 ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:104::1/64 "$llv1" In fib_tests.sh line 579: - 2001:db8:107::1/64 $lldummy "dummy0" ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:107::1/64 "$lldummy" "dummy0" In fib_tests.sh line 587: - 2001:db8:110::1/64 $llv1 "veth0" ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:110::1/64 "$llv1" "veth0" In fib_tests.sh line 684: err=`cat errors.txt |grep "Message too long"` ^-- SC2006 (style): Use $(...) notation instead of legacy backticks `...`. Did you mean: err=$(cat errors.txt |grep "Message too long") In fib_tests.sh line 731: err=`cat errors.txt |grep "Message too long"` ^-- SC2006 (style): Use $(...) notation instead of legacy backticks `...`. Did you mean: err=$(cat errors.txt |grep "Message too long") In fib_tests.sh line 762: if [ $num -ne $expected ]; then ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$num" -ne "$expected" ]; then In fib_tests.sh line 775: if [ $num -ne $expected ]; then ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$num" -ne "$expected" ]; then In fib_tests.sh line 807: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 812: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 819: $IP -6 route add 2001:30::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:30::"$i" \ In fib_tests.sh line 825: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 830: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 837: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 843: $IP -6 route replace 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route replace 2001:20::"$i" \ In fib_tests.sh line 848: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 856: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 861: $IP -6 route replace 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route replace 2001:20::"$i" \ In fib_tests.sh line 864: check_rt_num_clean 0 $($IP -6 route list |grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 868: check_rt_num 5 $($IP -6 route list |grep -v expires|grep 2001:20::|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^------------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 901: check_rt_num_clean 1 $($IP -6 route list|grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 905: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 943: printf " COMMAND: $cmd\n" ^-------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 947: out=$(eval $cmd $stderr) ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(eval "$cmd" $stderr) In fib_tests.sh line 949: if [ "$VERBOSE" = "1" -a -n "$out" ]; then ^-- SC2166 (warning): Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. In fib_tests.sh line 955: return $rc ^-^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: return "$rc" In fib_tests.sh line 970: printf " ${expected}\n" ^-----------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 977: out=$(echo ${out}) ^------------^ SC2116 (style): Useless echo? Instead of 'cmd $(echo foo)', just use 'cmd foo'. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(echo "${out}") In fib_tests.sh line 982: printf " ${out}\n" ^----------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 984: printf " ${expected}\n\n" ^-----------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 1006: [ $? -ne 0 ] && exit 1 ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1008: out=$($IP -6 ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP -6 ro ls match "${pfx}") In fib_tests.sh line 1015: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1034: set -- $expected ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: set -- "$expected" In fib_tests.sh line 1037: out=$($IP -6 ro ls match ${pfx} | sed -e 's/ pref medium//') ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP -6 ro ls match "${pfx}" | sed -e 's/ pref medium//') In fib_tests.sh line 1060: ip netns exec $ns2 sysctl -qw net.ipv4.ip_forward=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.ip_forward=1 In fib_tests.sh line 1061: ip netns exec $ns2 sysctl -qw net.ipv6.conf.all.forwarding=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv6.conf.all.forwarding=1 In fib_tests.sh line 1068: $IP li set veth2 netns $ns2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set veth2 netns "$ns2" up In fib_tests.sh line 1069: $IP li set veth4 netns $ns2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set veth4 netns "$ns2" up In fib_tests.sh line 1070: ip -netns $ns2 li add dummy1 type dummy ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" li add dummy1 type dummy In fib_tests.sh line 1071: ip -netns $ns2 li set dummy1 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" li set dummy1 up In fib_tests.sh line 1078: ip -netns $ns2 -6 addr add 2001:db8:101::2/64 dev veth2 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:101::2/64 dev veth2 nodad In fib_tests.sh line 1079: ip -netns $ns2 -6 addr add 2001:db8:103::2/64 dev veth4 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:103::2/64 dev veth4 nodad In fib_tests.sh line 1080: ip -netns $ns2 -6 addr add 2001:db8:104::1/64 dev dummy1 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:104::1/64 dev dummy1 nodad In fib_tests.sh line 1082: ip -netns $ns2 addr add 172.16.101.2/24 dev veth2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.101.2/24 dev veth2 In fib_tests.sh line 1083: ip -netns $ns2 addr add 172.16.103.2/24 dev veth4 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.103.2/24 dev veth4 In fib_tests.sh line 1084: ip -netns $ns2 addr add 172.16.104.1/24 dev dummy1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.104.1/24 dev dummy1 In fib_tests.sh line 1091: cleanup_ns $ns3 ^--^ SC2154 (warning): ns3 is referenced but not assigned. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: cleanup_ns "$ns3" In fib_tests.sh line 1105: ip link add veth5 netns $ns3 type veth peer name veth6 netns $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip link add veth5 netns "$ns3" type veth peer name veth6 netns "$ns2" In fib_tests.sh line 1106: ip -netns $ns3 link set veth5 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" link set veth5 up In fib_tests.sh line 1107: ip -netns $ns2 link set veth6 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set veth6 up In fib_tests.sh line 1109: ip -netns $ns3 -4 addr add dev veth5 172.16.105.1/24 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -4 addr add dev veth5 172.16.105.1/24 In fib_tests.sh line 1110: ip -netns $ns2 -4 addr add dev veth6 172.16.105.2/24 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -4 addr add dev veth6 172.16.105.2/24 In fib_tests.sh line 1111: ip -netns $ns3 -4 route add 172.16.100.0/22 via 172.16.105.2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -4 route add 172.16.100.0/22 via 172.16.105.2 In fib_tests.sh line 1113: ip -netns $ns3 -6 addr add dev veth5 2001:db8:105::1/64 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -6 addr add dev veth5 2001:db8:105::1/64 nodad In fib_tests.sh line 1114: ip -netns $ns2 -6 addr add dev veth6 2001:db8:105::2/64 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add dev veth6 2001:db8:105::2/64 nodad In fib_tests.sh line 1115: ip -netns $ns3 -6 route add 2001:db8:101::/33 via 2001:db8:105::2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -6 route add 2001:db8:101::/33 via 2001:db8:105::2 In fib_tests.sh line 1203: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1299: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1454: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1515: check_rt_num_clean 2 $($IP -6 route list|grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1521: check_rt_num 1 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1528: check_rt_num 1 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1533: check_rt_num 2 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1557: [ $? -ne 0 ] && exit 1 ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1559: out=$($IP ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP ro ls match "${pfx}") In fib_tests.sh line 1566: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1584: set -- $expected ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: set -- "$expected" In fib_tests.sh line 1588: out=$($IP ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP ro ls match "${pfx}") In fib_tests.sh line 1713: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1792: run_cmd "ip link set veth-inside netns $test-ns" ^---^ SC2154 (warning): test is referenced but not assigned (for output from commands, use "$(test ...)" ). In fib_tests.sh line 2133: $IP li add dummy${i} up type dummy ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li add dummy"${i}" up type dummy In fib_tests.sh line 2139: $IP li set dummy${i} vrf red ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set dummy"${i}" vrf red In fib_tests.sh line 2269: $IP li del dummy${i} ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li del dummy"${i}" In fib_tests.sh line 2352: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2363: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2384: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2385: ip netns exec $ns2 socat UDP4-LISTEN:54321,fork $tmp_file & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" socat UDP4-LISTEN:54321,fork "$tmp_file" & In fib_tests.sh line 2416: [[ $(cat $tmp_file | wc -l) -eq 3 ]] ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: [[ $(cat "$tmp_file" | wc -l) -eq 3 ]] In fib_tests.sh line 2424: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2442: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2443: ip netns exec $ns2 socat UDP6-LISTEN:54321,fork $tmp_file & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" socat UDP6-LISTEN:54321,fork "$tmp_file" & In fib_tests.sh line 2474: [[ $(cat $tmp_file | wc -l) -eq 3 ]] ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: [[ $(cat "$tmp_file" | wc -l) -eq 3 ]] In fib_tests.sh line 2482: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2490: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2565: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2571: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2586: ip -n $ns -j -s link show dev $dev \ ^-^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -n "$ns" -j -s link show dev "$dev" \ In fib_tests.sh line 2587: | jq '.[]["stats64"]["'$dir'"]["'$stat'"]' ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: | jq '.[]["stats64"]["'"$dir"'"]["'"$stat"'"]' In fib_tests.sh line 2595: local count=$(tail -n 1 $file | jq '.["counter-value"] | tonumber | floor') ^---^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local count=$(tail -n 1 "$file" | jq '.["counter-value"] | tonumber | floor') In fib_tests.sh line 2596: local ratio=$(echo "scale=2; $count / $expected" | bc -l) ^---^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2597: local res=$(echo "$ratio >= 0.95" | bc) ^-^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2628: local dmac=$(ip -n $ns2 -j link show dev veth2 | jq -r '.[]["address"]') ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local dmac=$(ip -n "$ns2" -j link show dev veth2 | jq -r '.[]["address"]') In fib_tests.sh line 2629: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2637: local t0_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t0_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2639: local t1_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t1_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2640: local diff=$(echo $t1_rx_pkts - $t0_rx_pkts | bc -l) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local diff=$(echo "$t1_rx_pkts" - "$t0_rx_pkts" | bc -l) In fib_tests.sh line 2641: list_rcv_eval $tmp_file $diff ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: list_rcv_eval "$tmp_file" "$diff" In fib_tests.sh line 2643: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2673: local dmac=$(ip -n $ns2 -j link show dev veth2 | jq -r '.[]["address"]') ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local dmac=$(ip -n "$ns2" -j link show dev veth2 | jq -r '.[]["address"]') In fib_tests.sh line 2674: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2682: local t0_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t0_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2684: local t1_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t1_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2685: local diff=$(echo $t1_rx_pkts - $t0_rx_pkts | bc -l) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local diff=$(echo "$t1_rx_pkts" - "$t0_rx_pkts" | bc -l) In fib_tests.sh line 2686: list_rcv_eval $tmp_file $diff ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: list_rcv_eval "$tmp_file" "$diff" In fib_tests.sh line 2688: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2693: tc_set_flower_counter $1 $2 $3 "src_ip $4 ip_proto tcp tcp_flags 0x2" ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter "$1" "$2" "$3" "src_ip $4 ip_proto tcp tcp_flags 0x2" In fib_tests.sh line 2715: ip netns exec $ns3 socat $ipver TCP-LISTEN:8000 STDIO >/dev/null & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns3" socat "$ipver" TCP-LISTEN:8000 STDIO >/dev/null & In fib_tests.sh line 2717: echo -n a | ip netns exec $ns1 socat $ipver STDIO TCP:$daddr:8000 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: echo -n a | ip netns exec "$ns1" socat "$ipver" STDIO TCP:"$daddr":8000 In fib_tests.sh line 2720: local -r syn0="$(tc_get_flower_counter $ns1 veth1)" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local -r syn0="$(tc_get_flower_counter "$ns1" veth1)" In fib_tests.sh line 2721: local -r syn1="$(tc_get_flower_counter $ns1 veth3)" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local -r syn1="$(tc_get_flower_counter "$ns1" veth3)" In fib_tests.sh line 2741: ip netns exec $ns1 \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" \ In fib_tests.sh line 2744: tc_set_flower_counter__saddr_syn $ns1 4 veth1 172.16.101.1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 4 veth1 172.16.101.1 In fib_tests.sh line 2745: tc_set_flower_counter__saddr_syn $ns1 4 veth3 172.16.103.1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 4 veth3 172.16.103.1 In fib_tests.sh line 2776: dev=$(get_route_dev_src 172.16.105.$i $src_ip) ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: dev=$(get_route_dev_src 172.16.105."$i" "$src_ip") In fib_tests.sh line 2790: if [ x"$pref_dev" = x"" ]; then ^----------^ SC2268 (style): Avoid x-prefix in comparisons as it no longer serves a purpose. Did you mean: if [ "$pref_dev" = "" ]; then In fib_tests.sh line 2833: ip netns exec $ns1 \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" \ In fib_tests.sh line 2836: tc_set_flower_counter__saddr_syn $ns1 6 veth1 2001:db8:101::1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 6 veth1 2001:db8:101::1 In fib_tests.sh line 2837: tc_set_flower_counter__saddr_syn $ns1 6 veth3 2001:db8:103::1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 6 veth3 2001:db8:103::1 In fib_tests.sh line 2873: v) VERBOSE=$(($VERBOSE + 1));; ^------^ SC2004 (style): $/${} is unnecessary on arithmetic variables. In fib_tests.sh line 2879: PEER_CMD="ip netns exec ${PEER_NS}" ^------^ SC2034 (warning): PEER_CMD appears unused. Verify use (or export if used externally). In fib_tests.sh line 2895: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2939: printf "\nTests passed: %3d\n" ${nsuccess} ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: printf "\nTests passed: %3d\n" "${nsuccess}" In fib_tests.sh line 2940: printf "Tests failed: %3d\n" ${nfail} ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: printf "Tests failed: %3d\n" "${nfail}" For more information: https://www.shellcheck.net/wiki/SC2034 -- PEER_CMD appears unused. Verify u... https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt... https://www.shellcheck.net/wiki/SC2154 -- ns1 is referenced but not assigned. ====== Checking the tree with the patch ====== Checking tools/testing/selftests/net/fib_tests.sh - 5cf2caf193ae0cd81b3c03740b5c0880a5f8fe5f1415d2463767ec3c2cb2bf69 In fib_tests.sh line 29: if [ ${rc} -eq ${expected} ]; then ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "${rc}" -eq "${expected}" ]; then In fib_tests.sh line 39: read a ^--^ SC2162 (info): read without -r will mangle backslashes. In fib_tests.sh line 47: read a ^--^ SC2162 (info): read without -r will mangle backslashes. In fib_tests.sh line 56: IP="$(which ip) -netns $ns1" ^--^ SC2154 (warning): ns1 is referenced but not assigned. In fib_tests.sh line 58: ip netns exec $ns1 sysctl -qw net.ipv4.ip_forward=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" sysctl -qw net.ipv4.ip_forward=1 In fib_tests.sh line 59: ip netns exec $ns1 sysctl -qw net.ipv6.conf.all.forwarding=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" sysctl -qw net.ipv6.conf.all.forwarding=1 In fib_tests.sh line 72: cleanup_ns $ns1 $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2154 (warning): ns2 is referenced but not assigned. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: cleanup_ns "$ns1" "$ns2" In fib_tests.sh line 80: addr=$($IP -6 -br addr show dev ${dev} | \ ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: addr=$($IP -6 -br addr show dev "${dev}" | \ In fib_tests.sh line 92: echo $addr ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: echo "$addr" In fib_tests.sh line 212: oif $down_dev &> /dev/null ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$down_dev" &> /dev/null In fib_tests.sh line 215: oif $down_dev &> /dev/null ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$down_dev" &> /dev/null In fib_tests.sh line 219: oif $up_dev &> /dev/null ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$up_dev" &> /dev/null In fib_tests.sh line 222: oif $up_dev &> /dev/null ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: oif "$up_dev" &> /dev/null In fib_tests.sh line 226: grep $down_dev | grep -q "dead linkdown" ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$down_dev" | grep -q "dead linkdown" In fib_tests.sh line 229: grep $down_dev | grep -q "dead linkdown" ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$down_dev" | grep -q "dead linkdown" In fib_tests.sh line 233: grep $up_dev | grep -q "dead linkdown" ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$up_dev" | grep -q "dead linkdown" In fib_tests.sh line 236: grep $up_dev | grep -q "dead linkdown" ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: grep "$up_dev" | grep -q "dead linkdown" In fib_tests.sh line 452: $IP link set dev veth2 netns $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP link set dev veth2 netns "$ns2" In fib_tests.sh line 454: ip -netns $ns2 address add 192.0.2.1/24 dev veth2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" address add 192.0.2.1/24 dev veth2 In fib_tests.sh line 456: ip -netns $ns2 link set dev veth2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev veth2 up In fib_tests.sh line 460: ip -netns $ns2 link set dev lo address 52:54:00:6a:c7:5e ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev lo address 52:54:00:6a:c7:5e In fib_tests.sh line 461: ip -netns $ns2 link set dev veth2 address 52:54:00:6a:c7:5e ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set dev veth2 address 52:54:00:6a:c7:5e In fib_tests.sh line 464: ip netns exec $ns2 tc qdisc add dev lo parent root handle 1: fq_codel ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc qdisc add dev lo parent root handle 1: fq_codel In fib_tests.sh line 465: ip netns exec $ns2 tc filter add dev lo parent 1: protocol arp basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev lo parent 1: protocol arp basic \ In fib_tests.sh line 467: ip netns exec $ns2 tc filter add dev lo parent 1: protocol ip basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev lo parent 1: protocol ip basic \ In fib_tests.sh line 485: ip netns exec $ns2 tc qdisc add dev veth2 ingress ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc qdisc add dev veth2 ingress In fib_tests.sh line 486: ip netns exec $ns2 tc filter add dev veth2 ingress protocol arp basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev veth2 ingress protocol arp basic \ In fib_tests.sh line 488: ip netns exec $ns2 tc filter add dev veth2 ingress protocol ip basic \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" tc filter add dev veth2 ingress protocol ip basic \ In fib_tests.sh line 494: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.rp_filter=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.rp_filter=1 In fib_tests.sh line 495: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.accept_local=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.accept_local=1 In fib_tests.sh line 496: ip netns exec $ns2 sysctl -qw net.ipv4.conf.all.route_localnet=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.conf.all.route_localnet=1 In fib_tests.sh line 528: printf "\n COMMAND: $cmd\n" ^---------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 531: out=$(eval $cmd 2>&1) ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(eval "$cmd" 2>&1) In fib_tests.sh line 533: if [ "$VERBOSE" = "1" -a -n "$out" ]; then ^-- SC2166 (warning): Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. In fib_tests.sh line 536: log_test $rc $erc "$desc" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: log_test $rc "$erc" "$desc" In fib_tests.sh line 549: local lldummy=$(get_linklocal dummy0) ^-----^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 550: local llv1=$(get_linklocal dummy0) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 569: - 2001:db8:103::1/64 $llv1 "veth0" ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:103::1/64 "$llv1" "veth0" In fib_tests.sh line 573: - 2001:db8:104::1/64 $llv1 ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:104::1/64 "$llv1" In fib_tests.sh line 581: - 2001:db8:107::1/64 $lldummy "dummy0" ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:107::1/64 "$lldummy" "dummy0" In fib_tests.sh line 589: - 2001:db8:110::1/64 $llv1 "veth0" ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: - 2001:db8:110::1/64 "$llv1" "veth0" In fib_tests.sh line 686: err=`cat errors.txt |grep "Message too long"` ^-- SC2006 (style): Use $(...) notation instead of legacy backticks `...`. Did you mean: err=$(cat errors.txt |grep "Message too long") In fib_tests.sh line 733: err=`cat errors.txt |grep "Message too long"` ^-- SC2006 (style): Use $(...) notation instead of legacy backticks `...`. Did you mean: err=$(cat errors.txt |grep "Message too long") In fib_tests.sh line 764: if [ $num -ne $expected ]; then ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$num" -ne "$expected" ]; then In fib_tests.sh line 777: if [ $num -ne $expected ]; then ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: if [ "$num" -ne "$expected" ]; then In fib_tests.sh line 809: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 814: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 821: $IP -6 route add 2001:30::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:30::"$i" \ In fib_tests.sh line 827: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 832: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 839: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 845: $IP -6 route replace 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route replace 2001:20::"$i" \ In fib_tests.sh line 850: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 858: $IP -6 route add 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route add 2001:20::"$i" \ In fib_tests.sh line 863: $IP -6 route replace 2001:20::$i \ ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP -6 route replace 2001:20::"$i" \ In fib_tests.sh line 866: check_rt_num_clean 0 $($IP -6 route list |grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 870: check_rt_num 5 $($IP -6 route list |grep -v expires|grep 2001:20::|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^------------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 903: check_rt_num_clean 1 $($IP -6 route list|grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 907: check_rt_num 0 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 945: printf " COMMAND: $cmd\n" ^-------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 949: out=$(eval $cmd $stderr) ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(eval "$cmd" $stderr) In fib_tests.sh line 951: if [ "$VERBOSE" = "1" -a -n "$out" ]; then ^-- SC2166 (warning): Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. In fib_tests.sh line 957: return $rc ^-^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: return "$rc" In fib_tests.sh line 972: printf " ${expected}\n" ^-----------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 979: out=$(echo ${out}) ^------------^ SC2116 (style): Useless echo? Instead of 'cmd $(echo foo)', just use 'cmd foo'. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$(echo "${out}") In fib_tests.sh line 984: printf " ${out}\n" ^----------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 986: printf " ${expected}\n\n" ^-----------------------^ SC2059 (info): Don't use variables in the printf format string. Use printf '..%s..' "$foo". In fib_tests.sh line 1008: [ $? -ne 0 ] && exit 1 ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1010: out=$($IP -6 ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP -6 ro ls match "${pfx}") In fib_tests.sh line 1017: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1036: set -- $expected ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: set -- "$expected" In fib_tests.sh line 1039: out=$($IP -6 ro ls match ${pfx} | sed -e 's/ pref medium//') ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP -6 ro ls match "${pfx}" | sed -e 's/ pref medium//') In fib_tests.sh line 1062: ip netns exec $ns2 sysctl -qw net.ipv4.ip_forward=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv4.ip_forward=1 In fib_tests.sh line 1063: ip netns exec $ns2 sysctl -qw net.ipv6.conf.all.forwarding=1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" sysctl -qw net.ipv6.conf.all.forwarding=1 In fib_tests.sh line 1070: $IP li set veth2 netns $ns2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set veth2 netns "$ns2" up In fib_tests.sh line 1071: $IP li set veth4 netns $ns2 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set veth4 netns "$ns2" up In fib_tests.sh line 1072: ip -netns $ns2 li add dummy1 type dummy ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" li add dummy1 type dummy In fib_tests.sh line 1073: ip -netns $ns2 li set dummy1 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" li set dummy1 up In fib_tests.sh line 1080: ip -netns $ns2 -6 addr add 2001:db8:101::2/64 dev veth2 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:101::2/64 dev veth2 nodad In fib_tests.sh line 1081: ip -netns $ns2 -6 addr add 2001:db8:103::2/64 dev veth4 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:103::2/64 dev veth4 nodad In fib_tests.sh line 1082: ip -netns $ns2 -6 addr add 2001:db8:104::1/64 dev dummy1 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add 2001:db8:104::1/64 dev dummy1 nodad In fib_tests.sh line 1084: ip -netns $ns2 addr add 172.16.101.2/24 dev veth2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.101.2/24 dev veth2 In fib_tests.sh line 1085: ip -netns $ns2 addr add 172.16.103.2/24 dev veth4 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.103.2/24 dev veth4 In fib_tests.sh line 1086: ip -netns $ns2 addr add 172.16.104.1/24 dev dummy1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" addr add 172.16.104.1/24 dev dummy1 In fib_tests.sh line 1093: cleanup_ns $ns3 ^--^ SC2154 (warning): ns3 is referenced but not assigned. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: cleanup_ns "$ns3" In fib_tests.sh line 1107: ip link add veth5 netns $ns3 type veth peer name veth6 netns $ns2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip link add veth5 netns "$ns3" type veth peer name veth6 netns "$ns2" In fib_tests.sh line 1108: ip -netns $ns3 link set veth5 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" link set veth5 up In fib_tests.sh line 1109: ip -netns $ns2 link set veth6 up ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" link set veth6 up In fib_tests.sh line 1111: ip -netns $ns3 -4 addr add dev veth5 172.16.105.1/24 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -4 addr add dev veth5 172.16.105.1/24 In fib_tests.sh line 1112: ip -netns $ns2 -4 addr add dev veth6 172.16.105.2/24 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -4 addr add dev veth6 172.16.105.2/24 In fib_tests.sh line 1113: ip -netns $ns3 -4 route add 172.16.100.0/22 via 172.16.105.2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -4 route add 172.16.100.0/22 via 172.16.105.2 In fib_tests.sh line 1115: ip -netns $ns3 -6 addr add dev veth5 2001:db8:105::1/64 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -6 addr add dev veth5 2001:db8:105::1/64 nodad In fib_tests.sh line 1116: ip -netns $ns2 -6 addr add dev veth6 2001:db8:105::2/64 nodad ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns2" -6 addr add dev veth6 2001:db8:105::2/64 nodad In fib_tests.sh line 1117: ip -netns $ns3 -6 route add 2001:db8:101::/33 via 2001:db8:105::2 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "$ns3" -6 route add 2001:db8:101::/33 via 2001:db8:105::2 In fib_tests.sh line 1205: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1301: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1456: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1517: check_rt_num_clean 2 $($IP -6 route list|grep expires|wc -l) || return ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1523: check_rt_num 1 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1530: check_rt_num 1 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1535: check_rt_num 2 $($IP -6 route list |grep expires|wc -l) ^-- SC2046 (warning): Quote this to prevent word splitting. ^----------^ SC2126 (style): Consider using 'grep -c' instead of 'grep|wc -l'. In fib_tests.sh line 1559: [ $? -ne 0 ] && exit 1 ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1561: out=$($IP ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP ro ls match "${pfx}") In fib_tests.sh line 1568: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 1586: set -- $expected ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: set -- "$expected" In fib_tests.sh line 1590: out=$($IP ro ls match ${pfx}) ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: out=$($IP ro ls match "${pfx}") In fib_tests.sh line 1715: if [ $? -eq 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if mycmd;', not indirectly with $?. In fib_tests.sh line 1794: run_cmd "ip link set veth-inside netns $test-ns" ^---^ SC2154 (warning): test is referenced but not assigned (for output from commands, use "$(test ...)" ). In fib_tests.sh line 2135: $IP li add dummy${i} up type dummy ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li add dummy"${i}" up type dummy In fib_tests.sh line 2141: $IP li set dummy${i} vrf red ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li set dummy"${i}" vrf red In fib_tests.sh line 2271: $IP li del dummy${i} ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: $IP li del dummy"${i}" In fib_tests.sh line 2354: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2365: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2386: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2387: ip netns exec $ns2 socat UDP4-LISTEN:54321,fork $tmp_file & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" socat UDP4-LISTEN:54321,fork "$tmp_file" & In fib_tests.sh line 2418: [[ $(cat $tmp_file | wc -l) -eq 3 ]] ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: [[ $(cat "$tmp_file" | wc -l) -eq 3 ]] In fib_tests.sh line 2426: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2444: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2445: ip netns exec $ns2 socat UDP6-LISTEN:54321,fork $tmp_file & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns2" socat UDP6-LISTEN:54321,fork "$tmp_file" & In fib_tests.sh line 2476: [[ $(cat $tmp_file | wc -l) -eq 3 ]] ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: [[ $(cat "$tmp_file" | wc -l) -eq 3 ]] In fib_tests.sh line 2484: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2492: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2567: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2573: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2588: ip -n $ns -j -s link show dev $dev \ ^-^ SC2086 (info): Double quote to prevent globbing and word splitting. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -n "$ns" -j -s link show dev "$dev" \ In fib_tests.sh line 2589: | jq '.[]["stats64"]["'$dir'"]["'$stat'"]' ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: | jq '.[]["stats64"]["'"$dir"'"]["'"$stat"'"]' In fib_tests.sh line 2597: local count=$(tail -n 1 $file | jq '.["counter-value"] | tonumber | floor') ^---^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local count=$(tail -n 1 "$file" | jq '.["counter-value"] | tonumber | floor') In fib_tests.sh line 2598: local ratio=$(echo "scale=2; $count / $expected" | bc -l) ^---^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2599: local res=$(echo "$ratio >= 0.95" | bc) ^-^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2630: local dmac=$(ip -n $ns2 -j link show dev veth2 | jq -r '.[]["address"]') ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local dmac=$(ip -n "$ns2" -j link show dev veth2 | jq -r '.[]["address"]') In fib_tests.sh line 2631: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2639: local t0_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t0_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2641: local t1_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t1_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2642: local diff=$(echo $t1_rx_pkts - $t0_rx_pkts | bc -l) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local diff=$(echo "$t1_rx_pkts" - "$t0_rx_pkts" | bc -l) In fib_tests.sh line 2643: list_rcv_eval $tmp_file $diff ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: list_rcv_eval "$tmp_file" "$diff" In fib_tests.sh line 2645: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2675: local dmac=$(ip -n $ns2 -j link show dev veth2 | jq -r '.[]["address"]') ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local dmac=$(ip -n "$ns2" -j link show dev veth2 | jq -r '.[]["address"]') In fib_tests.sh line 2676: local tmp_file=$(mktemp) ^------^ SC2155 (warning): Declare and assign separately to avoid masking return values. In fib_tests.sh line 2684: local t0_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t0_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2686: local t1_rx_pkts=$(link_stats_get $ns2 veth2 rx packets) ^--------^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local t1_rx_pkts=$(link_stats_get "$ns2" veth2 rx packets) In fib_tests.sh line 2687: local diff=$(echo $t1_rx_pkts - $t0_rx_pkts | bc -l) ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local diff=$(echo "$t1_rx_pkts" - "$t0_rx_pkts" | bc -l) In fib_tests.sh line 2688: list_rcv_eval $tmp_file $diff ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. ^---^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: list_rcv_eval "$tmp_file" "$diff" In fib_tests.sh line 2690: rm $tmp_file ^-------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: rm "$tmp_file" In fib_tests.sh line 2695: tc_set_flower_counter $1 $2 $3 "src_ip $4 ip_proto tcp tcp_flags 0x2" ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-- SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter "$1" "$2" "$3" "src_ip $4 ip_proto tcp tcp_flags 0x2" In fib_tests.sh line 2717: ip netns exec $ns3 socat $ipver TCP-LISTEN:8000 STDIO >/dev/null & ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns3" socat "$ipver" TCP-LISTEN:8000 STDIO >/dev/null & In fib_tests.sh line 2719: echo -n a | ip netns exec $ns1 socat $ipver STDIO TCP:$daddr:8000 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. ^----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: echo -n a | ip netns exec "$ns1" socat "$ipver" STDIO TCP:"$daddr":8000 In fib_tests.sh line 2722: local -r syn0="$(tc_get_flower_counter $ns1 veth1)" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local -r syn0="$(tc_get_flower_counter "$ns1" veth1)" In fib_tests.sh line 2723: local -r syn1="$(tc_get_flower_counter $ns1 veth3)" ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: local -r syn1="$(tc_get_flower_counter "$ns1" veth3)" In fib_tests.sh line 2743: ip netns exec $ns1 \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" \ In fib_tests.sh line 2746: tc_set_flower_counter__saddr_syn $ns1 4 veth1 172.16.101.1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 4 veth1 172.16.101.1 In fib_tests.sh line 2747: tc_set_flower_counter__saddr_syn $ns1 4 veth3 172.16.103.1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 4 veth3 172.16.103.1 In fib_tests.sh line 2778: dev=$(get_route_dev_src 172.16.105.$i $src_ip) ^-- SC2086 (info): Double quote to prevent globbing and word splitting. ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: dev=$(get_route_dev_src 172.16.105."$i" "$src_ip") In fib_tests.sh line 2792: if [ x"$pref_dev" = x"" ]; then ^----------^ SC2268 (style): Avoid x-prefix in comparisons as it no longer serves a purpose. Did you mean: if [ "$pref_dev" = "" ]; then In fib_tests.sh line 2835: ip netns exec $ns1 \ ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "$ns1" \ In fib_tests.sh line 2838: tc_set_flower_counter__saddr_syn $ns1 6 veth1 2001:db8:101::1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 6 veth1 2001:db8:101::1 In fib_tests.sh line 2839: tc_set_flower_counter__saddr_syn $ns1 6 veth3 2001:db8:103::1 ^--^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: tc_set_flower_counter__saddr_syn "$ns1" 6 veth3 2001:db8:103::1 In fib_tests.sh line 2875: v) VERBOSE=$(($VERBOSE + 1));; ^------^ SC2004 (style): $/${} is unnecessary on arithmetic variables. In fib_tests.sh line 2881: PEER_CMD="ip netns exec ${PEER_NS}" ^------^ SC2034 (warning): PEER_CMD appears unused. Verify use (or export if used externally). In fib_tests.sh line 2897: if [ $? -ne 0 ]; then ^-- SC2181 (style): Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. In fib_tests.sh line 2941: printf "\nTests passed: %3d\n" ${nsuccess} ^---------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: printf "\nTests passed: %3d\n" "${nsuccess}" In fib_tests.sh line 2942: printf "Tests failed: %3d\n" ${nfail} ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: printf "Tests failed: %3d\n" "${nfail}" For more information: https://www.shellcheck.net/wiki/SC2034 -- PEER_CMD appears unused. Verify u... https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt... https://www.shellcheck.net/wiki/SC2154 -- ns1 is referenced but not assigned.