From 298d70e8564f03c844435123bf36e84419c2f65a Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Mon, 31 Jan 2011 01:43:20 +0100 Subject: libxt_u32: enclose argument in quotes Otherwise ip6tables-save piped to ip6tables-restore can cause a parse error when the expression list is empty. Signed-off-by: Jan Engelhardt --- extensions/libxt_u32.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'extensions') diff --git a/extensions/libxt_u32.c b/extensions/libxt_u32.c index 054a5b24..378de0c9 100644 --- a/extensions/libxt_u32.c +++ b/extensions/libxt_u32.c @@ -45,6 +45,7 @@ static void u32_dump(const struct xt_u32 *data) const struct xt_u32_test *ct; unsigned int testind, i; + putchar('\"'); for (testind = 0; testind < data->ntests; ++testind) { ct = &data->tests[testind]; @@ -81,7 +82,7 @@ static void u32_dump(const struct xt_u32 *data) ct->value[i].max); } } - printf(" "); + printf("\" "); } /* string_to_number() is not quite what we need here ... */ -- cgit v1.2.3