mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 18:40:43 +03:00
Add ShellCheck's --enable=all inside scripts/
Strengthen static code analysis for shell scripts. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: John Kennedy <john.kennedy@delphix.com> Signed-off-by: szubersk <szuberskidamian@gmail.com> Closes #12914
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
#!/bin/sh
|
||||
# shellcheck disable=SC2154
|
||||
#
|
||||
# CDDL HEADER START
|
||||
#
|
||||
@@ -422,6 +423,8 @@ while getopts 'hvqxkfScRn:d:s:r:?t:T:u:I:' OPTION; do
|
||||
usage
|
||||
exit
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
@@ -442,7 +445,7 @@ if [ -n "$SINGLETEST" ]; then
|
||||
SINGLEQUIET="True"
|
||||
fi
|
||||
|
||||
cat >$RUNFILE_DIR/$RUNFILES << EOF
|
||||
cat >"${RUNFILE_DIR}/${RUNFILES}" << EOF
|
||||
[DEFAULT]
|
||||
pre =
|
||||
quiet = $SINGLEQUIET
|
||||
@@ -466,7 +469,7 @@ EOF
|
||||
CLEANUPSCRIPT="cleanup"
|
||||
fi
|
||||
|
||||
cat >>$RUNFILE_DIR/$RUNFILES << EOF
|
||||
cat >>"${RUNFILE_DIR}/${RUNFILES}" << EOF
|
||||
|
||||
[$SINGLETESTDIR]
|
||||
tests = ['$SINGLETESTFILE']
|
||||
@@ -745,4 +748,4 @@ if [ -n "$SINGLETEST" ]; then
|
||||
rm -f "$RUNFILES" >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
exit ${RESULT}
|
||||
exit "${RESULT}"
|
||||
|
||||
Reference in New Issue
Block a user