aboutsummaryrefslogtreecommitdiffstats
path: root/res/res_monitor.c
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-05 22:16:33 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-05 22:16:33 +0000
commita6d4c512c85a5c5a908521066fe4a7ba772e4aec (patch)
treeccaced165563a62abe8a3613e25cb0f1abc7295c /res/res_monitor.c
parent5d863dcd8db84fab3df37c0f32fb459fd1b94948 (diff)
reduce stack consumption for AMI and AMI/HTTP requests by nearly 20K in most cases
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@49676 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res/res_monitor.c')
-rw-r--r--res/res_monitor.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/res/res_monitor.c b/res/res_monitor.c
index 128f4d82f..a45c3a180 100644
--- a/res/res_monitor.c
+++ b/res/res_monitor.c
@@ -474,13 +474,13 @@ static char start_monitor_action_help[] =
" the input and output channels together after the\n"
" recording is finished.\n";
-static int start_monitor_action(struct mansession *s, struct message *m)
+static int start_monitor_action(struct mansession *s, const struct message *m)
{
struct ast_channel *c = NULL;
- char *name = astman_get_header(m, "Channel");
- char *fname = astman_get_header(m, "File");
- char *format = astman_get_header(m, "Format");
- char *mix = astman_get_header(m, "Mix");
+ const char *name = astman_get_header(m, "Channel");
+ const char *fname = astman_get_header(m, "File");
+ const char *format = astman_get_header(m, "Format");
+ const char *mix = astman_get_header(m, "Mix");
char *d;
if (ast_strlen_zero(name)) {
@@ -527,10 +527,10 @@ static char stop_monitor_action_help[] =
" started 'Monitor' action. The only parameter is 'Channel', the name\n"
" of the channel monitored.\n";
-static int stop_monitor_action(struct mansession *s, struct message *m)
+static int stop_monitor_action(struct mansession *s, const struct message *m)
{
struct ast_channel *c = NULL;
- char *name = astman_get_header(m, "Channel");
+ const char *name = astman_get_header(m, "Channel");
int res;
if (ast_strlen_zero(name)) {
astman_send_error(s, m, "No channel specified");
@@ -559,11 +559,11 @@ static char change_monitor_action_help[] =
" File - Required. Is the new name of the file created in the\n"
" monitor spool directory.\n";
-static int change_monitor_action(struct mansession *s, struct message *m)
+static int change_monitor_action(struct mansession *s, const struct message *m)
{
struct ast_channel *c = NULL;
- char *name = astman_get_header(m, "Channel");
- char *fname = astman_get_header(m, "File");
+ const char *name = astman_get_header(m, "Channel");
+ const char *fname = astman_get_header(m, "File");
if (ast_strlen_zero(name)) {
astman_send_error(s, m, "No channel specified");
return 0;
@@ -601,10 +601,10 @@ enum MONITOR_PAUSING_ACTION
MONITOR_ACTION_UNPAUSE
};
-static int do_pause_or_unpause(struct mansession *s, struct message *m, int action)
+static int do_pause_or_unpause(struct mansession *s, const struct message *m, int action)
{
struct ast_channel *c = NULL;
- char *name = astman_get_header(m, "Channel");
+ const char *name = astman_get_header(m, "Channel");
if (IS_NULL_STRING(name)) {
astman_send_error(s, m, "No channel specified");
@@ -633,7 +633,7 @@ static char pause_monitor_action_help[] =
" be used to control this:\n"
" Channel - Required. Used to specify the channel to record.\n";
-static int pause_monitor_action(struct mansession *s, struct message *m)
+static int pause_monitor_action(struct mansession *s, const struct message *m)
{
return do_pause_or_unpause(s, m, MONITOR_ACTION_PAUSE);
}
@@ -644,7 +644,7 @@ static char unpause_monitor_action_help[] =
" be used to control this:\n"
" Channel - Required. Used to specify the channel to record.\n";
-static int unpause_monitor_action(struct mansession *s, struct message *m)
+static int unpause_monitor_action(struct mansession *s, const struct message *m)
{
return do_pause_or_unpause(s, m, MONITOR_ACTION_UNPAUSE);
}