[asterisk-commits] tringenbach: branch 1.6.2 r277666 - in /branches/1.6.2: ./ main/features.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Jul 16 18:37:31 CDT 2010
Author: tringenbach
Date: Fri Jul 16 18:37:28 2010
New Revision: 277666
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=277666
Log:
Merged revisions 277657 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r277657 | tringenbach | 2010-07-16 18:23:15 -0500 (Fri, 16 Jul 2010) | 16 lines
Merged revisions 277625 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r277625 | tringenbach | 2010-07-16 17:43:39 -0500 (Fri, 16 Jul 2010) | 9 lines
Save and restore AST_FLAG_BRIDGE_HANGUP_DONT on attended transfer.
ast_bridge_call() clears AST_FLAG_BRIDGE_HANGUP_DONT. But during an attended
transfer, ast_bridge_call() is called for a second bridge on the same channel,
and it clears that flag, which still needs to get set for when the original
ast_bridge_call() gets control back and checks it.
Review: https://reviewboard.asterisk.org/r/741
........
................
Modified:
branches/1.6.2/ (props changed)
branches/1.6.2/main/features.c
Propchange: branches/1.6.2/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.
Modified: branches/1.6.2/main/features.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.2/main/features.c?view=diff&rev=277666&r1=277665&r2=277666
==============================================================================
--- branches/1.6.2/main/features.c (original)
+++ branches/1.6.2/main/features.c Fri Jul 16 18:37:28 2010
@@ -1480,6 +1480,8 @@
xferto, atxfernoanswertimeout, &outstate, transferer->cid.cid_num, transferer->cid.cid_name, 1, transferer->language);
if (!ast_check_hangup(transferer)) {
+ int hangup_dont = 0;
+
/* Transferer is up - old behaviour */
ast_indicate(transferer, -1);
if (!newchan) {
@@ -1501,7 +1503,18 @@
memset(&bconfig,0,sizeof(struct ast_bridge_config));
ast_set_flag(&(bconfig.features_caller), AST_FEATURE_DISCONNECT);
ast_set_flag(&(bconfig.features_callee), AST_FEATURE_DISCONNECT);
+
+ /* ast_bridge_call clears AST_FLAG_BRIDGE_HANGUP_DONT, but we don't
+ want that to happen here because we're also in another bridge already
+ */
+ if (ast_test_flag(chan, AST_FLAG_BRIDGE_HANGUP_DONT)) {
+ hangup_dont = 1;
+ }
res = ast_bridge_call(transferer, newchan, &bconfig);
+ if (hangup_dont) {
+ ast_set_flag(chan, AST_FLAG_BRIDGE_HANGUP_DONT);
+ }
+
if (ast_check_hangup(newchan) || !ast_check_hangup(transferer)) {
ast_hangup(newchan);
if (ast_stream_and_wait(transferer, xfersound, ""))
More information about the asterisk-commits
mailing list