From b0f2066ac0ebf3c5151ae2ece231b2317dfa3a5f Mon Sep 17 00:00:00 2001 From: Arturo Borrero Gonzalez Date: Fri, 19 Apr 2013 01:37:23 +0200 Subject: src: remove trailing newlines, tabs and spaces from XML format Delete all \n and \t from XML output, any reasonable XML viewer already does the nifty formatting for us. Signed-off-by: Arturo Borrero Gonzalez Signed-off-by: Pablo Neira Ayuso --- src/rule.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/rule.c') diff --git a/src/rule.c b/src/rule.c index 534526c..849cb41 100644 --- a/src/rule.c +++ b/src/rule.c @@ -459,17 +459,17 @@ static int nft_rule_snprintf_xml(char *buf, size_t size, struct nft_rule *r, list_for_each_entry(expr, &r->expr_list, head) { ret = snprintf(buf+offset, len, - "\n\t\n", expr->ops->name); + "", expr->ops->name); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); ret = expr->ops->snprintf(buf+offset, len, type, flags, expr); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); - ret = snprintf(buf+offset, len, "\n\t"); + ret = snprintf(buf+offset, len, ""); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); } - ret = snprintf(buf+offset, len, "\n\n "); + ret = snprintf(buf+offset, len, ""); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); return ret; -- cgit v1.2.3