diff options
author | rl1987 <rl1987@sdf.lonestar.org> | 2019-04-15 12:13:35 +0300 |
---|---|---|
committer | rl1987 <rl1987@sdf.lonestar.org> | 2019-04-15 12:13:35 +0300 |
commit | 55b4f02ba6cbbd4cae942a9e84e48e237d8e38aa (patch) | |
tree | 08519ce92e4fa1dccca05963850d4671ea188af8 | |
parent | 7b386f2356c9c706e9432b19058dee8147030056 (diff) | |
download | tor-55b4f02ba6cbbd4cae942a9e84e48e237d8e38aa.tar.gz tor-55b4f02ba6cbbd4cae942a9e84e48e237d8e38aa.zip |
Fix shellcheck warnings in fixup_filenames.sh
-rw-r--r-- | changes/ticket30078 | 3 | ||||
-rwxr-xr-x | src/test/fuzz/fixup_filenames.sh | 6 |
2 files changed, 6 insertions, 3 deletions
diff --git a/changes/ticket30078 b/changes/ticket30078 new file mode 100644 index 0000000000..5ab5abdbfd --- /dev/null +++ b/changes/ticket30078 @@ -0,0 +1,3 @@ + o Code simplification and refactoring (shell scripts): + - Fix shellcheck warnings in src/test/fuzz/fixup_filenames.sh. Resolves + issue 30078. diff --git a/src/test/fuzz/fixup_filenames.sh b/src/test/fuzz/fixup_filenames.sh index 68efc1abc5..f730d532a5 100755 --- a/src/test/fuzz/fixup_filenames.sh +++ b/src/test/fuzz/fixup_filenames.sh @@ -8,9 +8,9 @@ if [ ! -d "$1" ] ; then fi for fn in "$1"/* ; do - prev=`basename "$fn"` - post=`sha256sum "$fn" | sed -e 's/ .*//;'` - if [ "$prev" == "$post" ] ; then + prev=$(basename "$fn") + post=$(sha256sum "$fn" | sed -e 's/ .*//;') + if [ "$prev" = "$post" ] ; then echo "OK $prev" else echo "mv $prev $post" |