From: Felix Fietkau Date: Wed, 14 Mar 2012 15:32:06 +0000 (+0100) Subject: cli: prevent indenting if simple output is requested X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=f60010a4243f4ed134062ffd387b386ec9476cf4;p=oweals%2Fubus.git cli: prevent indenting if simple output is requested --- diff --git a/cli.c b/cli.c index 98744cf..de15947 100644 --- a/cli.c +++ b/cli.c @@ -72,7 +72,7 @@ static void receive_call_result_data(struct ubus_request *req, int type, struct if (!msg) return; - str = blobmsg_format_json_indent(msg, true, 0); + str = blobmsg_format_json_indent(msg, true, simple_output ? -1 : 0); printf("%s\n", str); free(str); }