[asterisk-commits] mmichelson: branch group/CCSS r213881 - in /team/group/CCSS: apps/ channels/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Aug 24 16:26:07 CDT 2009


Author: mmichelson
Date: Mon Aug 24 16:26:03 2009
New Revision: 213881

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=213881
Log:
Add appropriate method for handling call forward, and fix logic error in chan_sip.


Modified:
    team/group/CCSS/apps/app_dial.c
    team/group/CCSS/channels/chan_sip.c

Modified: team/group/CCSS/apps/app_dial.c
URL: http://svn.asterisk.org/svn-view/asterisk/team/group/CCSS/apps/app_dial.c?view=diff&rev=213881&r1=213880&r2=213881
==============================================================================
--- team/group/CCSS/apps/app_dial.c (original)
+++ team/group/CCSS/apps/app_dial.c Mon Aug 24 16:26:03 2009
@@ -782,6 +782,7 @@
 			 * any Dial operations that happen later won't record CC interfaces.
 			 */
 			cc_set_done_flag(o->chan);
+			ast_log(LOG_NOTICE, "Since we're forwarding to %s, we will not accept CC offers from him\n", o->chan->name);
 		} else
 			ast_log(LOG_NOTICE, "Unable to create local channel for call forward to '%s/%s' (cause = %d)\n", tech, stuff, cause);
 	}
@@ -981,6 +982,15 @@
 			/* here, o->chan == c == winner */
 			if (!ast_strlen_zero(c->call_forward)) {
 				pa->sentringing = 0;
+				if (!ignore_cc && (f = ast_read(c))) {
+					if (f->frametype == AST_FRAME_CONTROL && f->subclass == AST_CONTROL_CC) {
+						/* This channel is forwarding the call, and is capable of CC, so
+						 * be sure to add the new device interface to the list
+						 */
+						handle_cc_control_frame(c, f->data.ptr);
+					}
+					ast_frfree(f);
+				}
 				do_forward(o, &num, peerflags, single, to);
 				continue;
 			}

Modified: team/group/CCSS/channels/chan_sip.c
URL: http://svn.asterisk.org/svn-view/asterisk/team/group/CCSS/channels/chan_sip.c?view=diff&rev=213881&r1=213880&r2=213881
==============================================================================
--- team/group/CCSS/channels/chan_sip.c (original)
+++ team/group/CCSS/channels/chan_sip.c Mon Aug 24 16:26:03 2009
@@ -18884,7 +18884,7 @@
 				case 603: /* Decline */
 					if (p->owner) {
 						/* XXX TEMPORARY! FOR TESTING ONLY */
-						if (ast_get_cc_monitor_policy(p->cc_params) == AST_CC_AGENT_GENERIC) {
+						if (ast_get_cc_monitor_policy(p->cc_params) == AST_CC_MONITOR_GENERIC) {
 							ast_queue_control(p->owner, AST_CONTROL_CC);
 						}
 						ast_queue_control(p->owner, AST_CONTROL_BUSY);




More information about the asterisk-commits mailing list