summaryrefslogtreecommitdiff
path: root/tests/phdr-corruption.sh
diff options
context:
space:
mode:
authorBreno Rodrigues Guimaraes <brenorg@gmail.com>2023-03-11 11:34:25 -0300
committerBreno Rodrigues Guimaraes <brenorg@gmail.com>2023-03-11 11:37:11 -0300
commit8adc31ed7b30b689e50314c1c8a1842bc6e164af (patch)
tree75f3793d05ab86938a303eef4897412de18d704e /tests/phdr-corruption.sh
parent27cbc89d4830d5ae1fe3a2396f2a6042266895bc (diff)
downloadpatchelf-8adc31ed7b30b689e50314c1c8a1842bc6e164af.tar.gz
Fix all shellcheck issues
Diffstat (limited to 'tests/phdr-corruption.sh')
-rwxr-xr-xtests/phdr-corruption.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/phdr-corruption.sh b/tests/phdr-corruption.sh
index 4f6e901..274d6f1 100755
--- a/tests/phdr-corruption.sh
+++ b/tests/phdr-corruption.sh
@@ -15,7 +15,7 @@ cp "${SONAME}" "${SCRATCH}"
# Check for PT_PHDR entry VirtAddr corruption
readelfData=$(${READELF} -l "${SCRATCH_SO}" 2>&1)
-if [ "$(echo "$readelfData" | grep "PHDR" | wc -l)" != 1 ]; then
+if [ "$(echo "$readelfData" | grep -c "PHDR")" != 1 ]; then
# Triggered if PHDR errors appear on stderr
echo "ERROR: Unexpected number of occurences of PHDR in readelf results!"
exit 1