From: Mathieu Rene Date: Thu, 26 Feb 2009 17:08:41 +0000 (+0000) Subject: Add show api [name] and show application [name] X-Git-Tag: v1.0.4~1810 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=afd6c9f48175c7d89304c1ac1bdb3aa0fa6e1b9c;p=thirdparty%2Ffreeswitch.git Add show api [name] and show application [name] git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@12296 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/mod/applications/mod_commands/mod_commands.c b/src/mod/applications/mod_commands/mod_commands.c index 7883efd124..dba97c936a 100644 --- a/src/mod/applications/mod_commands/mod_commands.c +++ b/src/mod/applications/mod_commands/mod_commands.c @@ -2598,7 +2598,11 @@ SWITCH_STANDARD_API(show_function) } else if (!strcasecmp(command, "tasks")) { sprintf(sql, "select * from %s", command); } else if (!strcasecmp(command, "application") || !strcasecmp(command, "api")) { - sprintf(sql, "select name, description, syntax from interfaces where type = '%s' and description != '' order by type,name", command); + if (argv[1]) { + sprintf(sql, "select name, description, syntax from interfaces where type = '%s' and description != '' and name = '%s' order by type,name", command, argv[1]); + } else { + sprintf(sql, "select name, description, syntax from interfaces where type = '%s' and description != '' order by type,name", command); + } } else if (!strcasecmp(command, "calls")) { sprintf(sql, "select * from calls order by created_epoch"); if (argv[1] && !strcasecmp(argv[1],"count")) {