diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-11-20 17:33:06 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-11-20 17:33:06 +0000 |
commit | f16f0627aa78d9dc22e5b874d18edaea32c39843 (patch) | |
tree | c46006980d8a5ecd9f5385d47af91ae2f18b98c2 /apps/app_dial.c | |
parent | 390fec9a62d2d9e4410ef08f89acb5c7864a60cc (diff) |
Make sure to set the hangup cause on the calling channel in the case
that ast_call() fails. For incoming SIP channels, this was causing
us to send a 603 instead of a 486 when the call-limit was reached on
the destination channel.
(closes issue #13867)
Reported by: still_nsk
Patches:
13867.diff uploaded by putnopvut (license 60)
Tested by: blitzrage
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@158053 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_dial.c')
-rw-r--r-- | apps/app_dial.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/app_dial.c b/apps/app_dial.c index 1782e13f1..1cc08564a 100644 --- a/apps/app_dial.c +++ b/apps/app_dial.c @@ -1383,6 +1383,9 @@ static int dial_exec_full(struct ast_channel *chan, void *data, struct ast_flags ast_log(LOG_DEBUG, "ast call on peer returned %d\n", res); if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "Couldn't call %s\n", numsubst); + if (tmp->chan->hangupcause) { + chan->hangupcause = tmp->chan->hangupcause; + } ast_hangup(tmp->chan); tmp->chan = NULL; free(tmp); |