[svn-commits] pabelanger: branch pabelanger/issue17173 r258893 - in /team/pabelanger/issue1...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon Apr 26 07:08:34 CDT 2010


Author: pabelanger
Date: Mon Apr 26 07:08:30 2010
New Revision: 258893

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=258893
Log:
Cleanup whitespaces, add doxygen comments and sample ami_event.

Modified:
    team/pabelanger/issue17173/include/asterisk/manager.h
    team/pabelanger/issue17173/main/manager.c

Modified: team/pabelanger/issue17173/include/asterisk/manager.h
URL: http://svnview.digium.com/svn/asterisk/team/pabelanger/issue17173/include/asterisk/manager.h?view=diff&rev=258893&r1=258892&r2=258893
==============================================================================
--- team/pabelanger/issue17173/include/asterisk/manager.h (original)
+++ team/pabelanger/issue17173/include/asterisk/manager.h Mon Apr 26 07:08:30 2010
@@ -158,15 +158,16 @@
 	AST_RWLIST_ENTRY(manager_action) list;
 };
 
-/*! \brief External routines may register/unregister manager callbacks this way 
+/*! \brief External routines may register/unregister manager callbacks this way
  * \note  Use ast_manager_register2() to register with help text for new manager commands */
 #define ast_manager_register(a, b, c, d, e) ast_manager_register2(a, b, c, d, e, NULL)
 
 /*! \brief Register a manager callback using XML documentation to describe the manager. */
 #define ast_manager_register_xml(a, b, c, d) ast_manager_register2(a, b, c, d, NULL, NULL)
 
-/*! \brief Register a manager command with the manager interface 
- 	\param action Name of the requested Action:
+/*! \brief Register a manager command with the manager interface
+	\param type Type of the requested Action
+	\param action Name of the requested Action:
 	\param authority Required authority for this command
 	\param func Function to call for this command
 	\param synopsis Help text (one line, up to 30 chars) for CLI manager show commands

Modified: team/pabelanger/issue17173/main/manager.c
URL: http://svnview.digium.com/svn/asterisk/team/pabelanger/issue17173/main/manager.c?view=diff&rev=258893&r1=258892&r2=258893
==============================================================================
--- team/pabelanger/issue17173/main/manager.c (original)
+++ team/pabelanger/issue17173/main/manager.c Mon Apr 26 07:08:30 2010
@@ -694,6 +694,14 @@
 			For success returns, the module revision number is included.</para>
 		</description>
 	</ami_command>
+	<ami_event name="Reload" language="en_US">
+		<synopsis>
+		</sysnopsis>
+		<syntax>
+		</syntax>
+		<description>
+		</description>
+	</ami_event>
  ***/
 
 enum error_type {
@@ -709,7 +717,6 @@
 	FAILURE_DELETE,
 	FAILURE_APPEND
 };
-
 
 /*!
  * Linked list of events.
@@ -1141,7 +1148,6 @@
 	ao2_unlink(sessions, s);
 }
 
-
 static int check_manager_session_inuse(const char *name)
 {
 	struct mansession_session *session = ao2_find(sessions, (char *) name, 0);
@@ -1153,7 +1159,6 @@
 	}
 	return inuse;
 }
-
 
 /*!
  * lookup an entry in the list of registered users.
@@ -1282,11 +1287,13 @@
 	return CLI_SUCCESS;
 }
 
+/*! \brief CLI command manager show command. */
 static char *handle_showmancmd(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	return handle_show_manager_action(MANAGER_COMMAND, e, cmd, a);
 }
 
+/*! \brief CLI command manager show event. */
 static char *handle_show_manager_event(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	return handle_show_manager_action(MANAGER_EVENT, e, cmd, a);
@@ -1317,6 +1324,7 @@
 	return CLI_SUCCESS;
 }
 
+/*! \brief CLI command manager show user. */
 static char *handle_showmanager(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	struct ast_manager_user *user = NULL;
@@ -1381,7 +1389,7 @@
 	return CLI_SUCCESS;
 }
 
-
+/*! \brief CLI command manager show users. */
 static char *handle_showmanagers(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	struct ast_manager_user *user = NULL;
@@ -1465,19 +1473,19 @@
 	return CLI_SUCCESS;
 }
 
-/*! \brief  CLI command manager list commands */
+/*! \brief CLI command manager show commands */
 static char *handle_showmancmds(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	return handle_show_manager_actions(MANAGER_COMMAND, e, cmd, a);
 }
 
-/*! \brief  CLI command manager list events */
+/*! \brief CLI command manager show events */
 static char *handle_show_manager_events(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	return handle_show_manager_actions(MANAGER_EVENT, e, cmd, a);
 }
 
-/*! \brief CLI command manager list connected */
+/*! \brief CLI command manager show connected */
 static char *handle_showmanconn(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
 {
 	struct mansession_session *session;
@@ -1561,7 +1569,6 @@
 	reload_manager();
 	return CLI_SUCCESS;
 }
-
 
 static struct ast_cli_entry cli_manager[] = {
 	AST_CLI_DEFINE(handle_showmancmd, "Show a manager interface command"),
@@ -1628,7 +1635,6 @@
 	return __astman_get_header(m, var, GET_HEADER_FIRST_MATCH);
 }
 
-
 struct ast_variable *astman_get_variables(const struct message *m)
 {
 	int varlen, x, y;
@@ -1671,7 +1677,6 @@
 }
 
 /* access for hooks to send action messages to ami */
-
 int ast_hook_send_action(struct manager_custom_hook *hook, const char *msg)
 {
 	const char *action;
@@ -1731,7 +1736,6 @@
 	}
 	return ret;
 }
-
 
 /*!
  * helper function to send a string to the socket.
@@ -2291,9 +2295,6 @@
 
 	return 0;
 }
-
-
-
 
 /*! The amount of space in out must be at least ( 2 * strlen(in) + 1 ) */
 static void json_escape(char *out, const char *in)




More information about the svn-commits mailing list