]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 371861 via svnmerge from
authorAutomerge script <automerge@asterisk.org>
Wed, 29 Aug 2012 19:24:57 +0000 (19:24 +0000)
committerAutomerge script <automerge@asterisk.org>
Wed, 29 Aug 2012 19:24:57 +0000 (19:24 +0000)
file:///srv/subversion/repos/asterisk/branches/10

................
  r371861 | rmudgett | 2012-08-29 13:24:54 -0500 (Wed, 29 Aug 2012) | 15 lines

  Fix hangup cause passthrough regression.

  The v1.8 -r369258 change to fix the F and F(x) action logic introduced a
  regression in passing the hangup cause from the called channel to the
  caller channel.

  (closes issue ASTERISK-20287)
  Reported by: Konstantin Suvorov
  Patches:
        app_dial_hangupcause.patch (license #6421) patch uploaded by Konstantin Suvorov (modified)
  Tested by: rmudgett
  ........

  Merged revisions 371860 from http://svn.asterisk.org/svn/asterisk/branches/1.8
................

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10-digiumphones@371887 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_dial.c

index 2b0e2065cc6f0998e42461ea7a1f932f0a31137b..c3573f907da607508c791acf3f5000bcf636d332 100644 (file)
@@ -2994,9 +2994,9 @@ static int dial_exec_full(struct ast_channel *chan, const char *data, struct ast
                                        /* The peer is now running its own PBX. */
                                        goto out;
                                }
-                       } else {
-                               chan->hangupcause = peer->hangupcause;
                        }
+               } else if (!ast_check_hangup(chan)) {
+                       chan->hangupcause = peer->hangupcause;
                }
                ast_hangup(peer);
        }