Skip to contentSkip to conversation

tests: Fix for standalone calls to setlist_resize.sh

PATCH In review Phil Sutter 1 participant 2 messages Jul 22, 2025 – Mar 20 netfilter

lore
Share & tools
lore

Phil Sutter

author reviewer
#0 lore raw

PATCH 1/1 tests: Fix for standalone calls to setlist_resize.sh

If called without ip_set.ko loaded, the unconditional 'rmmod ip_set' at startup will fail and the previous 'set -e' makes that fatal.

Fixes ed47b815a0d2c ("tests: add namespace test and take into account delayed set removal at module remove")
---
 tests/setlist_resize.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/setlist_resize.sh +1 -1
index acb33e3ba0f08..db347ca065171 100755
@@ -20,7 +20,7 @@ while [ $n -le 9 ]; do
     	n=10
     fi
 done
-rmmod ip_set >/dev/null 2>&1
+rmmod ip_set >/dev/null 2>&1 || :
 
 create() {
     n=$1
Signature · 1 line
2.49.0
author reviewer
#1 lore raw
Quoted 5 lines · Phil Sutter

If called without ip_set.ko loaded, the unconditional 'rmmod ip_set' at startup will fail and the previous 'set -e' makes that fatal.

Fixes ed47b815a0d2c ("tests: add namespace test and take into account delayed set removal at module remove")

Patch applied.