summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
Diffstat (limited to 'res')
-rw-r--r--res/res_agi.c5
-rw-r--r--res/res_config_sqlite.c4
-rw-r--r--res/res_monitor.c10
-rw-r--r--res/res_stasis_answer.c3
4 files changed, 4 insertions, 18 deletions
diff --git a/res/res_agi.c b/res/res_agi.c
index 486310dd6..a841f3623 100644
--- a/res/res_agi.c
+++ b/res/res_agi.c
@@ -3625,11 +3625,6 @@ static enum agi_result agi_handle_command(struct ast_channel *chan, AGI *agi, ch
the module we are using */
if (c->mod != ast_module_info->self)
ast_module_ref(c->mod);
- /* If the AGI command being executed is an actual application (using agi exec)
- the app field will be updated in pbx_exec via handle_exec */
- if (ast_channel_cdr(chan) && !ast_check_hangup(chan) && strcasecmp(argv[0], "EXEC"))
- ast_cdr_setapp(ast_channel_cdr(chan), "AGI", buf);
-
res = c->handler(chan, agi, argc, argv);
if (c->mod != ast_module_info->self)
ast_module_unref(c->mod);
diff --git a/res/res_config_sqlite.c b/res/res_config_sqlite.c
index e648f941b..7d5fd83e6 100644
--- a/res/res_config_sqlite.c
+++ b/res/res_config_sqlite.c
@@ -791,7 +791,7 @@ static int cdr_handler(struct ast_cdr *cdr)
AST_RWLIST_TRAVERSE(&(tbl->columns), col, list) {
if (col->isint) {
- ast_cdr_getvar(cdr, col->name, &tmp, workspace, sizeof(workspace), 0, 1);
+ ast_cdr_format_var(cdr, col->name, &tmp, workspace, sizeof(workspace), 1);
if (!tmp) {
continue;
}
@@ -800,7 +800,7 @@ static int cdr_handler(struct ast_cdr *cdr)
ast_str_append(&sql2, 0, "%s%d", first ? "" : ",", scannum);
}
} else {
- ast_cdr_getvar(cdr, col->name, &tmp, workspace, sizeof(workspace), 0, 0);
+ ast_cdr_format_var(cdr, col->name, &tmp, workspace, sizeof(workspace), 0);
if (!tmp) {
continue;
}
diff --git a/res/res_monitor.c b/res/res_monitor.c
index f1da4ec83..b5225010e 100644
--- a/res/res_monitor.c
+++ b/res/res_monitor.c
@@ -692,18 +692,10 @@ static int start_monitor_exec(struct ast_channel *chan, const char *data)
}
if (!ast_strlen_zero(urlprefix) && !ast_strlen_zero(args.fname_base)) {
- struct ast_cdr *chan_cdr;
snprintf(tmp, sizeof(tmp), "%s/%s.%s", urlprefix, args.fname_base,
((strcmp(args.format, "gsm")) ? "wav" : "gsm"));
ast_channel_lock(chan);
- if (!ast_channel_cdr(chan)) {
- if (!(chan_cdr = ast_cdr_alloc())) {
- ast_channel_unlock(chan);
- return -1;
- }
- ast_channel_cdr_set(chan, chan_cdr);
- }
- ast_cdr_setuserfield(chan, tmp);
+ ast_cdr_setuserfield(ast_channel_name(chan), tmp);
ast_channel_unlock(chan);
}
if (waitforbridge) {
diff --git a/res/res_stasis_answer.c b/res/res_stasis_answer.c
index b7534b93d..53d4b06e2 100644
--- a/res/res_stasis_answer.c
+++ b/res/res_stasis_answer.c
@@ -42,10 +42,9 @@ static void *app_control_answer(struct stasis_app_control *control,
struct ast_channel *chan, void *data)
{
const int delay = 0;
- const int cdr_answer = 1;
ast_debug(3, "%s: Answering",
stasis_app_control_get_channel_id(control));
- return __ast_answer(chan, delay, cdr_answer) == 0 ? &OK : &FAIL;
+ return __ast_answer(chan, delay) == 0 ? &OK : &FAIL;
}
int stasis_app_control_answer(struct stasis_app_control *control)