summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2017-10-18 13:04:29 -0400
committerCorey Farrell <git@cfware.com>2017-10-18 12:13:22 -0500
commit91d02bdcfc8960e35a153f8871c928e18b4343dc (patch)
treeaa01f5dd953a8bf05c9086c5d2bcd4b1aeaa87a5 /channels
parent4865a05d4e8c32f25e2cfcbc0b3206ea6af08fd6 (diff)
chan_sip: Fix output of 'sip set debug off'.
When sip.conf contains 'sipdebug=yes' it is impossible to disable it using CLI 'sip set debug off'. This corrects the output of that CLI command to instruct the user to turn sipdebug off in the configuration file. ASTERISK-23462 #close Change-Id: I1cceade9caa9578e1b060feb832e3495ef5ad318
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index caf780282..ace1f823f 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -22635,7 +22635,12 @@ static char *sip_do_debug(struct ast_cli_entry *e, int cmd, struct ast_cli_args
} else if (!strcasecmp(what, "off")) {
sipdebug &= ~sip_debug_console;
sipdebug_text = 0;
- ast_cli(a->fd, "SIP Debugging Disabled\n");
+ if (sipdebug == sip_debug_none) {
+ ast_cli(a->fd, "SIP Debugging Disabled\n");
+ } else {
+ ast_cli(a->fd, "SIP Debugging still enabled due to configuration.\n");
+ ast_cli(a->fd, "Set sipdebug=no in sip.conf and reload to actually disable.\n");
+ }
return CLI_SUCCESS;
}
} else if (a->argc == e->args + 1) { /* ip/peer */