[Freeswitch-svn] [commit] r6617 - freeswitch/trunk/src/mod/applications/mod_dptools

Freeswitch SVN anthm at freeswitch.org
Mon Dec 10 20:05:52 EST 2007


Author: anthm
Date: Mon Dec 10 20:05:52 2007
New Revision: 6617

Modified:
   freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c

Log:
update

Modified: freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c	(original)
+++ freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c	Mon Dec 10 20:05:52 2007
@@ -1488,6 +1488,16 @@
 		d_dest = switch_channel_expand_variables(channel, dest);
 
 		if (switch_ivr_originate(session, new_session, &cause, d_dest, timelimit, NULL, NULL, NULL, NULL) == SWITCH_STATUS_SUCCESS) {
+			const char *context;
+			switch_caller_profile_t *cp;
+			switch_channel_t *new_channel = switch_core_session_get_channel(*new_session);
+			
+			if ((context = switch_channel_get_variable(new_channel, "inbound_context"))) {
+				if ((cp = switch_channel_get_caller_profile(new_channel))) {
+					cp->context = switch_core_strdup(cp->pool, context);
+				}
+			}
+			
 			switch_core_session_rwunlock(*new_session);
 		}
 



More information about the Freeswitch-svn mailing list