Skip to contentSkip to conversation

src: meter: avoid double-space in list ruleset output

PATCH In review Florian Westphal 2 participants 2 messages Sep 19, 2019 – Sep 20, 2019 netfilter

lore
Share & tools
lore

Florian Westphal

author maintainer
#0 lore raw

PATCH 1/1 src: meter: avoid double-space in list ruleset output

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

---
 src/statement.c                                                 | 2 +-
 tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
src/statement.c +1 -1
index 5aa5b1e0bda4..af84e06c971e 100644
@@ -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, " }");
 
 }
 
tests/shell/testcases/sets/dumps/0022type_selective_flush_0.nft +1 -1
index e518906cc35b..5a6e3261b4ba 100644
@@ -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 }
 	}
 }
Signature · 1 line
2.21.0