netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH nft] src: meter: avoid double-space in list ruleset output
@ 2019-09-19  9:23 Florian Westphal
  2019-09-20  9:29 ` Pablo Neira Ayuso
  0 siblings, 1 reply; 2+ messages in thread
From: Florian Westphal @ 2019-09-19  9:23 UTC (permalink / raw)
  To: netfilter-devel; +Cc: Florian Westphal

changes
meter f size 1024 { ip saddr limit rate 10/second}  accept
to
meter f size 1024 { ip saddr limit rate 10/second } accept

Signed-off-by: Florian Westphal <fw@strlen.de>
---
 src/statement.c                                                 | 2 +-
 tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/statement.c b/src/statement.c
index 5aa5b1e0bda4..af84e06c971e 100644
--- a/src/statement.c
+++ b/src/statement.c
@@ -128,7 +128,7 @@ static void meter_stmt_print(const struct stmt *stmt, struct output_ctx *octx)
 	stmt_print(stmt->meter.stmt, octx);
 	octx->flags = flags;
 
-	nft_print(octx, "} ");
+	nft_print(octx, " }");
 
 }
 
diff --git a/tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft b/tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft
index e518906cc35b..5a6e3261b4ba 100644
--- a/tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft
+++ b/tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft
@@ -8,6 +8,6 @@ table ip t {
 	}
 
 	chain c {
-		tcp dport 80 meter f size 1024 { ip saddr limit rate 10/second} 
+		tcp dport 80 meter f size 1024 { ip saddr limit rate 10/second }
 	}
 }
-- 
2.21.0


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

* Re: [PATCH nft] src: meter: avoid double-space in list ruleset output
  2019-09-19  9:23 [PATCH nft] src: meter: avoid double-space in list ruleset output Florian Westphal
@ 2019-09-20  9:29 ` Pablo Neira Ayuso
  0 siblings, 0 replies; 2+ messages in thread
From: Pablo Neira Ayuso @ 2019-09-20  9:29 UTC (permalink / raw)
  To: Florian Westphal; +Cc: netfilter-devel

On Thu, Sep 19, 2019 at 11:23:46AM +0200, Florian Westphal wrote:
> changes
> meter f size 1024 { ip saddr limit rate 10/second}  accept
> to
> meter f size 1024 { ip saddr limit rate 10/second } accept
> 
> Signed-off-by: Florian Westphal <fw@strlen.de>

Acked-by: Pablo Neira Ayuso <pablo@netfilter.org>

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

end of thread, other threads:[~2019-09-20  9:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-19  9:23 [PATCH nft] src: meter: avoid double-space in list ruleset output Florian Westphal
2019-09-20  9:29 ` Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).