]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
asterisk: Export additional manager functions
authorSean Bright <sean.bright@gmail.com>
Fri, 18 Dec 2020 15:16:38 +0000 (10:16 -0500)
committerGeorge Joseph <gjoseph@digium.com>
Wed, 6 Jan 2021 15:11:43 +0000 (09:11 -0600)
Rename check_manager_enabled() and check_webmanager_enabled() to begin
with ast_ so that the symbols are automatically exported by the
linker.

ASTERISK~29184

Change-Id: I85762b9a5d14500c15f6bad6507138c8858644c9

include/asterisk/manager.h
main/asterisk.c
main/manager.c

index 6aea1d05ab32dbb604f85d09560730068fbbc043..a2af10bdb92388d58a7b149822dfc8c96aeb9d75 100644 (file)
@@ -115,10 +115,10 @@ struct manager_custom_hook {
 };
 
 /*! \brief Check if AMI is enabled */
-int check_manager_enabled(void);
+int ast_manager_check_enabled(void);
 
 /*! \brief Check if AMI/HTTP is enabled */
-int check_webmanager_enabled(void);
+int ast_webmanager_check_enabled(void);
 
 /*! Add a custom hook to be called when an event is fired
  \param hook struct manager_custom_hook object to add
index a028611dba656d24ace202ae047c8647d54e721f..ec1d5dbba8562066b15af83ecf9582bb3035bcbd 100644 (file)
@@ -537,8 +537,8 @@ static char *handle_show_settings(struct ast_cli_entry *e, int cmd, struct ast_c
 
        ast_cli(a->fd, "\n* Subsystems\n");
        ast_cli(a->fd, "  -------------\n");
-       ast_cli(a->fd, "  Manager (AMI):               %s\n", check_manager_enabled() ? "Enabled" : "Disabled");
-       ast_cli(a->fd, "  Web Manager (AMI/HTTP):      %s\n", check_webmanager_enabled() ? "Enabled" : "Disabled");
+       ast_cli(a->fd, "  Manager (AMI):               %s\n", ast_manager_check_enabled() ? "Enabled" : "Disabled");
+       ast_cli(a->fd, "  Web Manager (AMI/HTTP):      %s\n", ast_webmanager_check_enabled() ? "Enabled" : "Disabled");
        ast_cli(a->fd, "  Call data records:           %s\n", ast_cdr_is_enabled() ? "Enabled" : "Disabled");
        ast_cli(a->fd, "  Realtime Architecture (ARA): %s\n", ast_realtime_enabled() ? "Enabled" : "Disabled");
 
index 562a7ea088f0c6c129722f46f2363a92c8c60e6a..fc99c9635027d1c6829e93a72a134a6e88c00622 100644 (file)
@@ -1946,12 +1946,12 @@ void ast_manager_unregister_hook(struct manager_custom_hook *hook)
        AST_RWLIST_UNLOCK(&manager_hooks);
 }
 
-int check_manager_enabled(void)
+int ast_manager_check_enabled(void)
 {
        return manager_enabled;
 }
 
-int check_webmanager_enabled(void)
+int ast_webmanager_check_enabled(void)
 {
        return (webmanager_enabled && manager_enabled);
 }
@@ -6309,7 +6309,7 @@ static int action_coresettings(struct mansession *s, const struct message *m)
                        ast_option_maxfiles,
                        AST_CLI_YESNO(ast_realtime_enabled()),
                        AST_CLI_YESNO(ast_cdr_is_enabled()),
-                       AST_CLI_YESNO(check_webmanager_enabled())
+                       AST_CLI_YESNO(ast_webmanager_check_enabled())
                        );
        return 0;
 }