diff options
author | Matthew Jordan <mjordan@digium.com> | 2012-07-10 22:26:27 +0000 |
---|---|---|
committer | Matthew Jordan <mjordan@digium.com> | 2012-07-10 22:26:27 +0000 |
commit | 2ffae5745d6d68f1599f4dfbf0ead131cf5acc32 (patch) | |
tree | 1304cf10595e850a33e2dbb2458a2819751bc1ce /main/logger.c | |
parent | 3805e2ae4d654a24f7c98fc6f41dcec81d02670e (diff) |
Add some additional documentation for core AMI events
This patch adds some basic documentation for a number of modules. This
includes core source files in Asterisk (those in main), as well as
chan_agent, chan_dahdi, chan_local, sig_analog, and sig_pri. The DTD
has also been updated to allow referencing of AMI commands.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369905 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/logger.c')
-rw-r--r-- | main/logger.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/main/logger.c b/main/logger.c index ca2648190..6d6227bfc 100644 --- a/main/logger.c +++ b/main/logger.c @@ -793,6 +793,16 @@ static int reload_logger(int rotate, const char *altconf) AST_RWLIST_TRAVERSE(&logchannels, f, list) { if (f->disabled) { f->disabled = 0; /* Re-enable logging at reload */ + /*** DOCUMENTATION + <managerEventInstance> + <synopsis>Raised when a logging channel is re-enabled after a reload operation.</synopsis> + <syntax> + <parameter name="Channel"> + <para>The name of the logging channel.</para> + </parameter> + </syntax> + </managerEventInstance> + ***/ manager_event(EVENT_FLAG_SYSTEM, "LogChannel", "Channel: %s\r\nEnabled: Yes\r\n", f->filename); } if (f->fileptr && (f->fileptr != stdout) && (f->fileptr != stderr)) { @@ -1089,6 +1099,16 @@ static void logger_print_normal(struct logmsg *logmsg) fprintf(stderr, "Asterisk logging error: Out of disk space, can't log to log file %s\n", chan->filename); else fprintf(stderr, "Logger Warning: Unable to write to log file '%s': %s (disabled)\n", chan->filename, strerror(errno)); + /*** DOCUMENTATION + <managerEventInstance> + <synopsis>Raised when a logging channel is disabled.</synopsis> + <syntax> + <parameter name="Channel"> + <para>The name of the logging channel.</para> + </parameter> + </syntax> + </managerEventInstance> + ***/ manager_event(EVENT_FLAG_SYSTEM, "LogChannel", "Channel: %s\r\nEnabled: No\r\nReason: %d - %s\r\n", chan->filename, errno, strerror(errno)); chan->disabled = 1; } else if (res > 0) { |