[nft PATCH 3/4] rule: delete extra space in sets printing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The extra space is printed when sets are printed in tabulated format.
However, the space is still required in printing in plain format (ie, monitor).

Signed-off-by: Arturo Borrero Gonzalez <arturo.borrero.glez@xxxxxxxxx>
---
 0 files changed

diff --git a/src/rule.c b/src/rule.c
index c0e45aa..ab39513 100644
--- a/src/rule.c
+++ b/src/rule.c
@@ -267,7 +267,10 @@ static void set_print_declaration(const struct set *set,
 	if (opts->table != NULL)
 		printf(" %s", opts->table);
 
-	printf(" %s { %s", set->handle.set, opts->nl);
+	printf(" %s {%s", set->handle.set, opts->nl);
+
+	if (!strcmp(opts->nl, ""))
+		printf(" ");
 
 	printf("%s%stype %s", opts->tab, opts->tab, set->keytype->name);
 	if (set->flags & SET_F_MAP)

--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux