aboutsummaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
Diffstat (limited to 'res')
-rw-r--r--res/res_agi.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/res/res_agi.c b/res/res_agi.c
index cb0d7a917..ece9c0bbe 100644
--- a/res/res_agi.c
+++ b/res/res_agi.c
@@ -2589,6 +2589,11 @@ static int agi_handle_command(struct ast_channel *chan, AGI *agi, char *buf, int
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 (chan->cdr && !ast_check_hangup(chan) && strcasecmp(argv[0], "EXEC"))
+ ast_cdr_setapp(chan->cdr, "AGI", buf);
+
res = c->handler(chan, agi, argc, argv);
if (c->mod != ast_module_info->self)
ast_module_unref(c->mod);