diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2025-03-13 22:28:27 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2025-03-18 16:37:47 +0100 |
commit | f133180ee0c72f4a0de4a7acad8a9d8476914bd4 (patch) | |
tree | 365c36aef5c5c268b4e04bf80b18efd737f86f67 /tests/shell/testcases/transactions | |
parent | 3e50cd6b063d64c2e72b0e32bc36dd5a22f75c06 (diff) |
src: print set element with multi-word description in single one line
If the set element:
- represents a mapping
- has a timeout
- has a comment
- has counter/quota/limit
- concatenation (already printed in a single line before this patch)
ie. if the set element requires several words, then print it in one
single line.
Before this patch:
table ip x {
set y {
typeof ip saddr
counter
elements = { 192.168.10.35 counter packets 0 bytes 0, 192.168.10.101 counter packets 0 bytes 0,
192.168.10.135 counter packets 0 bytes 0 }
}
}
After this patch:
table ip x {
set y {
typeof ip saddr
counter
elements = { 192.168.10.35 counter packets 0 bytes 0,
192.168.10.101 counter packets 0 bytes 0,
192.168.10.135 counter packets 0 bytes 0 }
}
}
Acked-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/shell/testcases/transactions')
-rw-r--r-- | tests/shell/testcases/transactions/dumps/0047set_0.nft | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/tests/shell/testcases/transactions/dumps/0047set_0.nft b/tests/shell/testcases/transactions/dumps/0047set_0.nft index 4da397b2..d8e8e38a 100644 --- a/tests/shell/testcases/transactions/dumps/0047set_0.nft +++ b/tests/shell/testcases/transactions/dumps/0047set_0.nft @@ -2,10 +2,15 @@ table ip filter { map group_10060 { type ipv4_addr : classid flags interval - elements = { 10.1.26.2 : 1:bbf8, 10.1.26.3 : 1:c1ad, - 10.1.26.4 : 1:b2d7, 10.1.26.5 : 1:f705, - 10.1.26.6 : 1:b895, 10.1.26.7 : 1:ec4c, - 10.1.26.8 : 1:de78, 10.1.26.9 : 1:b4f3, - 10.1.26.10 : 1:dec6, 10.1.26.11 : 1:b4c0 } + elements = { 10.1.26.2 : 1:bbf8, + 10.1.26.3 : 1:c1ad, + 10.1.26.4 : 1:b2d7, + 10.1.26.5 : 1:f705, + 10.1.26.6 : 1:b895, + 10.1.26.7 : 1:ec4c, + 10.1.26.8 : 1:de78, + 10.1.26.9 : 1:b4f3, + 10.1.26.10 : 1:dec6, + 10.1.26.11 : 1:b4c0 } } } |