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.VH5GLJ3c2s and /tmp/tmp.ZNp1VzhNzN Tree base: 4a12ff213d4b ("net: preserve MSG_ZEROCOPY with forwarding") Now at: 9fb8d75d4069 ("selftest: net: extend msg_zerocopy test with forwarding") ====== Checking before the patch ====== Checking tools/testing/selftests/net/msg_zerocopy.sh - 8cfef7abde43ea4d99e8e13fbe161ff7d0a7ab3ca3d6e46ab53e756d1f1e1435 In msg_zerocopy.sh line 12: readonly RAND="$(mktemp -u XXXXXX)" ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. In msg_zerocopy.sh line 44: readonly EXTRA_ARGS="$@" ^--^ SC2124 (warning): Assigning an array to a string! Assign as array, or use * instead of @ to concatenate. In msg_zerocopy.sh line 110: local readonly ARGS="$1" ^------^ SC2316 (error): This applies local to the variable named readonly, which is probably not what you want. Use a separate command or the appropriate `declare` options instead. ^------^ SC2034 (warning): readonly appears unused. Verify use (or export if used externally). In msg_zerocopy.sh line 113: ip netns exec "${NS2}" "${BIN}" "-${IP}" -i "${DEV}" -t 2 -C 2 -S "${SADDR}" -D "${DADDR}" ${ARGS} -r "${RXMODE}" & ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "${NS2}" "${BIN}" "-${IP}" -i "${DEV}" -t 2 -C 2 -S "${SADDR}" -D "${DADDR}" "${ARGS}" -r "${RXMODE}" & In msg_zerocopy.sh line 115: ip netns exec "${NS1}" "${BIN}" "-${IP}" -i "${DEV}" -t 1 -C 3 -S "${SADDR}" -D "${DADDR}" ${ARGS} "${TXMODE}" ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip netns exec "${NS1}" "${BIN}" "-${IP}" -i "${DEV}" -t 1 -C 3 -S "${SADDR}" -D "${DADDR}" "${ARGS}" "${TXMODE}" For more information: https://www.shellcheck.net/wiki/SC2316 -- This applies local to the variabl... https://www.shellcheck.net/wiki/SC2034 -- readonly appears unused. Verify u... https://www.shellcheck.net/wiki/SC2124 -- Assigning an array to a string! A... ====== Checking the tree with the patch ====== Checking tools/testing/selftests/net/msg_zerocopy.sh - 8cfef7abde43ea4d99e8e13fbe161ff7d0a7ab3ca3d6e46ab53e756d1f1e1435 In msg_zerocopy.sh line 13: readonly RAND="$(mktemp -u XXXXXX)" ^--^ SC2155 (warning): Declare and assign separately to avoid masking return values. In msg_zerocopy.sh line 49: readonly EXTRA_ARGS="$@" ^--^ SC2124 (warning): Assigning an array to a string! Assign as array, or use * instead of @ to concatenate. In msg_zerocopy.sh line 116: ip -netns "${NS1}" addr add "${SADDR}/${MASK}" dev "${DEV}" ${NODAD} ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "${NS1}" addr add "${SADDR}/${MASK}" dev "${DEV}" "${NODAD}" In msg_zerocopy.sh line 117: ip -netns "${NS2}" addr add "${DADDR}/${MASK}" dev "${DEV}" ${NODAD} ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "${NS2}" addr add "${DADDR}/${MASK}" dev "${DEV}" "${NODAD}" In msg_zerocopy.sh line 118: ip -netns "${NS2}" addr add "${DUMMY_ADDR}/${MASK}" dev "${DUMMY_DEV}" ${NODAD} ^------^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: ip -netns "${NS2}" addr add "${DUMMY_ADDR}/${MASK}" dev "${DUMMY_DEV}" "${NODAD}" In msg_zerocopy.sh line 132: local readonly ARGS="$1" ^------^ SC2316 (error): This applies local to the variable named readonly, which is probably not what you want. Use a separate command or the appropriate `declare` options instead. ^------^ SC2034 (warning): readonly appears unused. Verify use (or export if used externally). In msg_zerocopy.sh line 140: -S "${SADDR}" -D "${DADDR}" ${ARGS} -r "${RXMODE}" & ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: -S "${SADDR}" -D "${DADDR}" "${ARGS}" -r "${RXMODE}" & In msg_zerocopy.sh line 143: -S "${SADDR}" -D "${DADDR}" ${ARGS} "${TXMODE}" -Z 0 || ret=1 ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: -S "${SADDR}" -D "${DADDR}" "${ARGS}" "${TXMODE}" -Z 0 || ret=1 In msg_zerocopy.sh line 155: -S "${SADDR}" -D "${DADDR_TXONLY}" ${ARGS} "${TXMODE}" -Z 1 || ret=1 ^-----^ SC2086 (info): Double quote to prevent globbing and word splitting. Did you mean: -S "${SADDR}" -D "${DADDR_TXONLY}" "${ARGS}" "${TXMODE}" -Z 1 || ret=1 For more information: https://www.shellcheck.net/wiki/SC2316 -- This applies local to the variabl... https://www.shellcheck.net/wiki/SC2034 -- readonly appears unused. Verify u... https://www.shellcheck.net/wiki/SC2124 -- Assigning an array to a string! A...