[asterisk-commits] oej: branch oej/pinedanish-copybridgeflags-1.6.0 r313092 - in /team/oej/pined...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Apr 7 10:25:33 CDT 2011


Author: oej
Date: Thu Apr  7 10:25:29 2011
New Revision: 313092

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=313092
Log:
Make sure we can copy flags through multiple local channels and still be able to do that PBX dtmf transfer.

Modified:
    team/oej/pinedanish-copybridgeflags-1.6.0/apps/app_dial.c
    team/oej/pinedanish-copybridgeflags-1.6.0/channels/chan_local.c
    team/oej/pinedanish-copybridgeflags-1.6.0/main/features.c

Modified: team/oej/pinedanish-copybridgeflags-1.6.0/apps/app_dial.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinedanish-copybridgeflags-1.6.0/apps/app_dial.c?view=diff&rev=313092&r1=313091&r2=313092
==============================================================================
--- team/oej/pinedanish-copybridgeflags-1.6.0/apps/app_dial.c (original)
+++ team/oej/pinedanish-copybridgeflags-1.6.0/apps/app_dial.c Thu Apr  7 10:25:29 2011
@@ -2010,11 +2010,11 @@
 
 				ast_channel_setoption(chan, AST_OPTION_OPRMODE, &oprmode, sizeof(oprmode), 0);
 			}
-			ast_debug(1, "--- Settings bridgeflags on %s\n", chan->name);
+			ast_debug(1, "--- Setting bridgeflags on %s\n", chan->name);
 			ast_copy_flags(&chan->bridgeflags, &config.features_callee,
 				AST_FEATURE_REDIRECT | AST_FEATURE_DISCONNECT |
 				AST_FEATURE_AUTOMON | AST_FEATURE_PARKCALL | AST_FEATURE_AUTOMIXMON);
-			ast_debug(1, "--- Settings bridgeflags on %s\n", peer->name);
+			ast_debug(1, "--- Setting bridgeflags on %s\n", peer->name);
 			ast_copy_flags(&peer->bridgeflags, &config.features_caller,
 				AST_FEATURE_REDIRECT | AST_FEATURE_DISCONNECT |
 				AST_FEATURE_AUTOMON | AST_FEATURE_PARKCALL | AST_FEATURE_AUTOMIXMON);

Modified: team/oej/pinedanish-copybridgeflags-1.6.0/channels/chan_local.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinedanish-copybridgeflags-1.6.0/channels/chan_local.c?view=diff&rev=313092&r1=313091&r2=313092
==============================================================================
--- team/oej/pinedanish-copybridgeflags-1.6.0/channels/chan_local.c (original)
+++ team/oej/pinedanish-copybridgeflags-1.6.0/channels/chan_local.c Thu Apr  7 10:25:29 2011
@@ -304,6 +304,9 @@
 					ast_queue_control_data(p->owner, AST_CONTROL_BRIDGEPARAM, &p->chan->bridgeflags, sizeof(p->chan->bridgeflags));
 					ast_debug(1, "----- Sending bridge flags from channel %s upstream to %s\n", p->chan->name, p->owner->name);
 					ast_debug(1, "----- We have these channels to play with: 1: %s 2: %s \n", p->chan->name, p->owner->name);
+					if (ast_test_flag(&p->chan->bridgeflags, AST_FEATURE_REDIRECT)) {
+						ast_debug(2, "--- Package includes transfer flag\n");
+					}
 					ast_channel_unlock(p->owner);
 				}
 				ast_channel_unlock(p->chan->_bridge);

Modified: team/oej/pinedanish-copybridgeflags-1.6.0/main/features.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinedanish-copybridgeflags-1.6.0/main/features.c?view=diff&rev=313092&r1=313091&r2=313092
==============================================================================
--- team/oej/pinedanish-copybridgeflags-1.6.0/main/features.c (original)
+++ team/oej/pinedanish-copybridgeflags-1.6.0/main/features.c Thu Apr  7 10:25:29 2011
@@ -2478,6 +2478,16 @@
                                 	ast_set_flag(&(config->features_callee), AST_FEATURE_PARKCALL);
 					ast_set_flag(config, AST_BRIDGE_DTMF_CHANNEL_1);
 				}
+
+				ast_debug(1, "--- Setting bridgeflags on %s\n", chan->name);
+				ast_copy_flags(&chan->bridgeflags, &(config->features_callee),
+					AST_FEATURE_REDIRECT | AST_FEATURE_DISCONNECT |
+					AST_FEATURE_AUTOMON | AST_FEATURE_PARKCALL | AST_FEATURE_AUTOMIXMON);
+				ast_debug(1, "--- Setting bridgeflags on %s\n", peer->name);
+				ast_copy_flags(&peer->bridgeflags, &(config->features_caller),
+					AST_FEATURE_REDIRECT | AST_FEATURE_DISCONNECT |
+					AST_FEATURE_AUTOMON | AST_FEATURE_PARKCALL | AST_FEATURE_AUTOMIXMON);
+	
 				ast_debug(2, "--- Setting updated bridge flags from chan_local in this bridge for outgoing channel %s Peer %s\n", chan->name, peer->name);
 				break;
 			case AST_CONTROL_OPTION:




More information about the asterisk-commits mailing list