]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
add some magic vars
authorAnthony Minessale <anthony.minessale@gmail.com>
Wed, 19 Nov 2008 20:42:28 +0000 (20:42 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Wed, 19 Nov 2008 20:42:28 +0000 (20:42 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@10466 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/switch_ivr.c

index 4b2d1282f586ec4942e0a01a1d9614ac57d07838..4d2a92e35e6bf2576f03abb83cdbad26678702bc 100644 (file)
@@ -1057,7 +1057,8 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_session_transfer(switch_core_session_
        switch_channel_clear_state_handler(channel, NULL);
 
        if ((profile = switch_channel_get_caller_profile(channel))) {
-
+               const char *var;
+               
                if (switch_strlen_zero(dialplan)) {
                        dialplan = profile->dialplan;
                }
@@ -1078,6 +1079,14 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_session_transfer(switch_core_session_
                        extension = "service";
                }
 
+               if ((var = switch_channel_get_variable(channel, "force_transfer_dialplan"))) {
+                       dialplan = var;
+               }
+
+               if ((var = switch_channel_get_variable(channel, "force_transfer_context"))) {
+                       context = var;
+               }
+               
                new_profile = switch_caller_profile_clone(session, profile);
 
                new_profile->dialplan = switch_core_strdup(new_profile->pool, dialplan);