summaryrefslogtreecommitdiff
path: root/apps/app_dial.c
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2006-05-16 23:39:29 +0000
committerJoshua Colp <jcolp@digium.com>2006-05-16 23:39:29 +0000
commitd2da48b1566b940138e73b627b927027dee45d0a (patch)
tree822b3cfbeb74c4d2b488a98eb6e86e97e87f9544 /apps/app_dial.c
parentc3dce57d95b4f313dde62f4d607a30f5c101596c (diff)
Inherit channel variables when call forwarding through chan_local (issue #7095 reported by raarts)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27595 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps/app_dial.c')
-rw-r--r--apps/app_dial.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/app_dial.c b/apps/app_dial.c
index b3fe1c023..da44e5820 100644
--- a/apps/app_dial.c
+++ b/apps/app_dial.c
@@ -472,6 +472,8 @@ static struct ast_channel *wait_for_answer(struct ast_channel *in, struct dial_l
c = o->chan = ast_request(tech, in->nativeformats, stuff, &cause);
if (!c)
ast_log(LOG_NOTICE, "Unable to create local channel for call forward to '%s/%s' (cause = %d)\n", tech, stuff, cause);
+ else
+ ast_channel_inherit_variables(in, o->chan);
} else {
if (option_verbose > 2)
ast_verbose(VERBOSE_PREFIX_3 "Too many forwards from %s\n", c->name);
@@ -1051,6 +1053,8 @@ static int dial_exec_full(struct ast_channel *chan, void *data, struct ast_flags
tmp->chan = ast_request(tech, chan->nativeformats, stuff, &cause);
if (!tmp->chan)
ast_log(LOG_NOTICE, "Unable to create local channel for call forward to '%s/%s' (cause = %d)\n", tech, stuff, cause);
+ else
+ ast_channel_inherit_variables(chan, tmp->chan);
} else {
if (option_verbose > 2)
ast_verbose(VERBOSE_PREFIX_3 "Too many forwards from %s\n", tmp->chan->name);