From d3722382bdd467d1c705911450120be75426406f Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Fri, 24 Feb 2012 15:08:34 +0100 Subject: [PATCH] Do quote section names to keep the same style as option values --- file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/file.c b/file.c index b471307..c2b0e72 100644 --- a/file.c +++ b/file.c @@ -566,7 +566,7 @@ static void uci_export_package(struct uci_package *p, FILE *stream, bool header) struct uci_section *sec = uci_to_section(s); fprintf(stream, "\nconfig %s", uci_escape(ctx, sec->type)); if (!sec->anonymous || (ctx->flags & UCI_FLAG_EXPORT_NAME)) - fprintf(stream, " %s", uci_escape(ctx, sec->e.name)); + fprintf(stream, " '%s'", uci_escape(ctx, sec->e.name)); fprintf(stream, "\n"); uci_foreach_element(&sec->options, o) { struct uci_option *opt = uci_to_option(o); -- 2.11.0