]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Add enabled/disabled information for rtautoclear sip show settings output.
authorJeff Peeler <jpeeler@digium.com>
Tue, 2 Nov 2010 23:02:51 +0000 (23:02 +0000)
committerJeff Peeler <jpeeler@digium.com>
Tue, 2 Nov 2010 23:02:51 +0000 (23:02 +0000)
When setting to zero/"no", the numeric default was shown making it not obvious
the disabled setting was respected.

(closes issue #18123)
Reported by: zerohalo

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@293722 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index 1d693a18edccfa9f6b48d4e9d5fe793af3d6c8c2..c6d1a8941a45f6e0f6f7a34b3694f5d379f0268f 100644 (file)
@@ -11845,7 +11845,7 @@ static int sip_show_settings(int fd, int argc, char *argv[])
                ast_cli(fd, "  Update:                 %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_RTUPDATE) ? "Yes" : "No");
                ast_cli(fd, "  Ignore Reg. Expire:     %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_IGNOREREGEXPIRE) ? "Yes" : "No");
                ast_cli(fd, "  Save sys. name:         %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_RTSAVE_SYSNAME) ? "Yes" : "No");
-               ast_cli(fd, "  Auto Clear:             %d\n", global_rtautoclear);
+               ast_cli(fd, "  Auto Clear:             %d (%s)", global_rtautoclear, ast_test_flag(&global_flags[1], SIP_PAGE2_RTAUTOCLEAR) ? "Enabled" : "Disabled");
        }
        ast_cli(fd, "\n----\n");
        return RESULT_SUCCESS;