]> sourceware.org Git - systemtap.git/commitdiff
testsuite/systemtap.base/perf.sh drop bashism
authorSevan Janiyan <venture37@geeklan.co.uk>
Wed, 2 Jun 2021 18:55:53 +0000 (14:55 -0400)
committerFrank Ch. Eigler <fche@redhat.com>
Wed, 2 Jun 2021 18:55:53 +0000 (14:55 -0400)
You don't need to use == to check for equality in a test statement, a
single equals sign is sufficient. The use of double equals sign is a
bashism which doesn't always translate as intended on other shells.

[fche checked other scripts in the source tree that used [ == ]; they
are all marked /bin/bash so can stay as is.]

testsuite/systemtap.base/perf.sh

index 9a0c79861d6ad59b0cf05c2dc1be0a398c8129f2..3081b72c5a9b02ae3d2cecca21e598e5c9dffcc8 100755 (executable)
@@ -56,7 +56,7 @@ probe end
 done
 
 
-if [ "${perfresult['first']}" == "${perfresult['second']}" ] ; then
+if [ "${perfresult['first']}" = "${perfresult['second']}" ] ; then
     echo PASS: ${perfresult["first"]}
 else
     echo UNRESOLVED: ${perfresult["first"]} ${perfresult["second"]}
This page took 0.029754 seconds and 5 git commands to generate.