aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authorbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-05-02 20:25:42 +0000
committerbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-05-02 20:25:42 +0000
commitef68dab0186d17a3597f67c3c81e5871aee2728e (patch)
tree5cbfe3eda4693de9a7551853ab720b0b3e74ea04 /channels
parent26000ee774d06e86e107fa05396b99f3ecd22090 (diff)
Add new "pri show version" command to show the libpri version for support reasons.
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@115257 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_zap.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/channels/chan_zap.c b/channels/chan_zap.c
index 0653a2a36..fc016bac9 100644
--- a/channels/chan_zap.c
+++ b/channels/chan_zap.c
@@ -9609,6 +9609,13 @@ static int handle_pri_set_debug_file(int fd, int argc, char **argv)
return RESULT_SUCCESS;
}
+#ifdef HAVE_PRI_VERSION
+static int handle_pri_version(int fd, int agc, char *argv[]) {
+ ast_cli(fd, "libpri version: %s\n", pri_get_version());
+ return RESULT_SUCCESS;
+}
+#endif
+
static int handle_pri_debug(int fd, int argc, char *argv[])
{
int span;
@@ -9845,6 +9852,11 @@ static struct ast_cli_entry zap_pri_cli[] = {
{ { "pri", "unset", "debug", "file", NULL },
handle_pri_set_debug_file, "Ends PRI debug output to file" },
+
+#ifdef HAVE_PRI_VERSION
+ { { "pri", "show", "version", NULL },
+ handle_pri_version, "Displays version of libpri" },
+#endif
};
#endif /* HAVE_PRI */