Linux Netfilter development
 help / color / mirror / Atom feed
* [PATCH nftables] tests: shell: fix typo in vmap_timeout test script
@ 2025-10-26 20:41 Gyorgy Sarvari
  2025-10-26 21:58 ` Florian Westphal
  0 siblings, 1 reply; 2+ messages in thread
From: Gyorgy Sarvari @ 2025-10-26 20:41 UTC (permalink / raw)
  To: netfilter-devel

While executing the test suite from tests/shell folder, the following error
is displayed many times:

tests/shell/testcases/maps/vmap_timeout: line 48: [: : integer expected

Looking at the script, a non-existing variable (expires) is tested instead of
the existing one (expire).

This change corrects this.

Reproduction:
NFTABLESLIB=/usr/lib/nftables
tests/shell/run-tests.sh -v

Signed-off-by: Gyorgy Sarvari <skandigraun@gmail.com>
---
 tests/shell/testcases/maps/vmap_timeout | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/shell/testcases/maps/vmap_timeout b/tests/shell/testcases/maps/vmap_timeout
index 8ac7e8e7..55d1c1b9 100755
--- a/tests/shell/testcases/maps/vmap_timeout
+++ b/tests/shell/testcases/maps/vmap_timeout
@@ -45,7 +45,7 @@ for i in $(seq 1 100) ; do
 		expire=$((RANDOM%utimeout))
 
 		expire_str=""
-		if [ "$expires" -gt 0 ]; then
+		if [ "$expire" -gt 0 ]; then
 			expire_str="expires ${expire}s"
 		fi
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH nftables] tests: shell: fix typo in vmap_timeout test script
  2025-10-26 20:41 [PATCH nftables] tests: shell: fix typo in vmap_timeout test script Gyorgy Sarvari
@ 2025-10-26 21:58 ` Florian Westphal
  0 siblings, 0 replies; 2+ messages in thread
From: Florian Westphal @ 2025-10-26 21:58 UTC (permalink / raw)
  To: Gyorgy Sarvari; +Cc: netfilter-devel

Gyorgy Sarvari <skandigraun@gmail.com> wrote:
> While executing the test suite from tests/shell folder, the following error
> is displayed many times:
> 
> tests/shell/testcases/maps/vmap_timeout: line 48: [: : integer expected

Applied, thank you.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-10-26 21:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-26 20:41 [PATCH nftables] tests: shell: fix typo in vmap_timeout test script Gyorgy Sarvari
2025-10-26 21:58 ` Florian Westphal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox