[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[groff] 04/24: Really fix Savannah #66479.
From: |
G. Branden Robinson |
Subject: |
[groff] 04/24: Really fix Savannah #66479. |
Date: |
Mon, 2 Dec 2024 22:52:27 -0500 (EST) |
gbranden pushed a commit to branch master
in repository groff.
commit 744b93212aa073bd06c037444b6fe612f2240837
Author: Sven Schober <sv3sch@gmail.com>
AuthorDate: Sat Nov 30 22:31:33 2024 +0000
Really fix Savannah #66479.
* contrib/hdtbl/examples/test-hdtbl.sh.in:
* tmac/tests/an_vertical-margins-are-correct.sh:
* tmac/tests/doc-old_vertical-margins-are-correct.sh:
* tmac/tests/doc_vertical-margins-are-correct.sh: Use POSIX shell
arithmetic instead of trying to be clever with expr(1).
Fixes <https://savannah.gnu.org/bugs/?66479>.
---
contrib/hdtbl/examples/test-hdtbl.sh.in | 2 +-
tmac/tests/an_vertical-margins-are-correct.sh | 2 +-
tmac/tests/doc-old_vertical-margins-are-correct.sh | 2 +-
tmac/tests/doc_vertical-margins-are-correct.sh | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/contrib/hdtbl/examples/test-hdtbl.sh.in
b/contrib/hdtbl/examples/test-hdtbl.sh.in
index 3b5088db6..05ed2b1d7 100644
--- a/contrib/hdtbl/examples/test-hdtbl.sh.in
+++ b/contrib/hdtbl/examples/test-hdtbl.sh.in
@@ -44,7 +44,7 @@ check_number_pages()
res=$("$gs_program" -o /dev/null/ -sDEVICE=bbox "$1" 2>&1 \
| grep HiResBoundingBox | wc -l)
# macOS `wc` prefixes the line count with spaces. Get rid of them.
- res=$(expr "$res" + 0) || exit 99
+ res=$(( res + 0 )) || exit 99
if [ "$res" != $2 ]
then
diff --git a/tmac/tests/an_vertical-margins-are-correct.sh
b/tmac/tests/an_vertical-margins-are-correct.sh
index f8c211cdf..2482da436 100755
--- a/tmac/tests/an_vertical-margins-are-correct.sh
+++ b/tmac/tests/an_vertical-margins-are-correct.sh
@@ -91,7 +91,7 @@ echo "$output"
echo "checking page length" >&2
res=$(echo "$output" | wc -l)
# macOS `wc` prefixes the line count with spaces. Get rid of them.
-res=$(expr "$res" + 0) || exit 99
+res=$(( res + 0 )) || exit 99
test "$res" = 66 || wail
echo "checking placement of page header" >&2
diff --git a/tmac/tests/doc-old_vertical-margins-are-correct.sh
b/tmac/tests/doc-old_vertical-margins-are-correct.sh
index e7ce92ed3..3005c32ed 100755
--- a/tmac/tests/doc-old_vertical-margins-are-correct.sh
+++ b/tmac/tests/doc-old_vertical-margins-are-correct.sh
@@ -93,7 +93,7 @@ echo "$output"
echo "checking page length" >&2
res=$(echo "$output" | wc -l)
# macOS `wc` prefixes the line count with spaces. Get rid of them.
-res=$(expr "$res" + 0) || exit 99
+res=$(( res + 0 )) || exit 99
test "$res" = 66 || wail
echo "checking placement of page header" >&2
diff --git a/tmac/tests/doc_vertical-margins-are-correct.sh
b/tmac/tests/doc_vertical-margins-are-correct.sh
index 90f922393..7d66d2bbf 100755
--- a/tmac/tests/doc_vertical-margins-are-correct.sh
+++ b/tmac/tests/doc_vertical-margins-are-correct.sh
@@ -93,7 +93,7 @@ echo "$output"
echo "checking page length" >&2
res=$(echo "$output" | wc -l)
# macOS `wc` prefixes the line count with spaces. Get rid of them.
-res=$(expr "$res" + 0) || exit 99
+res=$(( res + 0 )) || exit 99
test "$res" = 66 || wail
echo "checking placement of page header" >&2
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [groff] 04/24: Really fix Savannah #66479.,
G. Branden Robinson <=