From: Vincent Bernat Date: Sat, 9 May 2015 10:50:10 +0000 (+0200) Subject: client: complain if the provided format is not supported X-Git-Tag: 0.7.15~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a742670827b8ffb553f3443b2f4bf1136a500e1d;p=thirdparty%2Flldpd.git client: complain if the provided format is not supported --- diff --git a/src/client/lldpcli.c b/src/client/lldpcli.c index 8eeac70e..af6e0c3b 100644 --- a/src/client/lldpcli.c +++ b/src/client/lldpcli.c @@ -277,7 +277,10 @@ cmd_exec(lldpctl_conn_t *conn, const char *fmt, int argc, const char **argv) #ifdef USE_JSONC else if (strcmp(fmt, "json") == 0) w = jsonc_init(stdout); #endif - else w = txt_init(stdout); + else { + log_warnx("lldpctl", "unknown output format \"%s\"", fmt); + w = txt_init(stdout); + } /* Execute command */ int rc = commands_execute(conn, w,