[svn-commits] mmichelson: branch mmichelson/issue13630 r188458 - in /team/mmichelson/issue1...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Apr 14 16:11:45 CDT 2009


Author: mmichelson
Date: Tue Apr 14 16:11:42 2009
New Revision: 188458

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=188458
Log:
Get the skeleton of what is necessary put in.


Modified:
    team/mmichelson/issue13630/include/asterisk/channel.h
    team/mmichelson/issue13630/main/channel.c
    team/mmichelson/issue13630/res/res_features.c

Modified: team/mmichelson/issue13630/include/asterisk/channel.h
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/issue13630/include/asterisk/channel.h?view=diff&rev=188458&r1=188457&r2=188458
==============================================================================
--- team/mmichelson/issue13630/include/asterisk/channel.h (original)
+++ team/mmichelson/issue13630/include/asterisk/channel.h Tue Apr 14 16:11:42 2009
@@ -716,6 +716,11 @@
 
 struct ast_channel *__ast_request_and_dial(const char *type, int format, void *data, int timeout, int *reason, const char *cidnum, const char *cidname, struct outgoing_helper *oh);
 
+/*!
+ * \brief general method for handling a call forward.
+ */
+int ast_forward_call(void);
+
 /*!\brief Register a channel technology (a new channel driver)
  * Called by a channel module to register the kind of channels it supports.
  * \param tech Structure defining channel technology or "type"

Modified: team/mmichelson/issue13630/main/channel.c
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/issue13630/main/channel.c?view=diff&rev=188458&r1=188457&r2=188458
==============================================================================
--- team/mmichelson/issue13630/main/channel.c (original)
+++ team/mmichelson/issue13630/main/channel.c Tue Apr 14 16:11:42 2009
@@ -3076,6 +3076,12 @@
 				break;
 			if (timeout > -1)
 				timeout = res;
+
+			if (!ast_strlen_zero(chan->call_forward)) {
+				ast_forward_call();
+				continue;
+			}
+
 			f = ast_read(chan);
 			if (!f) {
 				*outstate = AST_CONTROL_HANGUP;
@@ -3151,6 +3157,12 @@
 struct ast_channel *ast_request_and_dial(const char *type, int format, void *data, int timeout, int *outstate, const char *cidnum, const char *cidname)
 {
 	return __ast_request_and_dial(type, format, data, timeout, outstate, cidnum, cidname, NULL);
+}
+
+int ast_forward_call(void)
+{
+	/* stub */
+	return 0;
 }
 
 struct ast_channel *ast_request(const char *type, int format, void *data, int *cause)

Modified: team/mmichelson/issue13630/res/res_features.c
URL: http://svn.digium.com/svn-view/asterisk/team/mmichelson/issue13630/res/res_features.c?view=diff&rev=188458&r1=188457&r2=188458
==============================================================================
--- team/mmichelson/issue13630/res/res_features.c (original)
+++ team/mmichelson/issue13630/res/res_features.c Tue Apr 14 16:11:42 2009
@@ -1446,6 +1446,11 @@
 					continue;
 
 				if (chan && (chan == active_channel)){
+
+					if (!ast_strlen_zero(chan->call_forward)) {
+						ast_forward_call();
+						continue;
+					}
 					f = ast_read(chan);
 					if (f == NULL) { /*doh! where'd he go?*/
 						state = AST_CONTROL_HANGUP;




More information about the svn-commits mailing list