# Bitmap comment: Delete test set
0 ipset destroy test
# Bitmap comment: create set with timeout
-0 ipset create test bitmap:ip range 2.0.0.1-2.1.0.0 comment timeout 5
+0 ipset create test bitmap:ip range 2.0.0.1-2.1.0.0 comment timeout 3
# Bitmap comment: Add multiple elements with default timeout
0 for x in `seq 1 255`; do echo "add test 2.0.0.$x comment \\\"text message $x\\\""; done | ipset restore
# Bitmap comment: Add multiple elements with zero timeout
0 ipset save test | sort > .foo.1
# IP: Compare save and restore
0 (sort iphash.t.large > .foo.2) && (cmp .foo.1 .foo.2)
+# IP: Delete all elements, one by one
+0 ipset list test | sed '1,/Members/d' | xargs -n1 ipset del test
# IP: Delete test set
0 ipset x test
# Network: Create a set
esac
echo -ne "$types: $what: "
cmd=`echo $cmd | sed "s|ipset|$ipset 2>.foo.err|"`
+ # For the case: ipset list | ... | xargs -n1 ipset
+ cmd=`echo $cmd | sed "s|ipset|$ipset|"`
eval $cmd
r=$?
# echo $ret $r