]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-4053 try this
authorAnthony Minessale <anthm@freeswitch.org>
Fri, 30 Mar 2012 19:24:50 +0000 (14:24 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Fri, 30 Mar 2012 19:24:50 +0000 (14:24 -0500)
src/switch_channel.c
src/switch_core_session.c

index 58f72e504d8419157146d894b9a4c579a42cbc64..c3970ea8e2a913e13be3b90e5ab031c229800040 100644 (file)
@@ -831,7 +831,7 @@ SWITCH_DECLARE(const char *) switch_channel_get_variable_partner(switch_channel_
        switch_assert(channel != NULL);
 
        if (!zstr(varname)) {
-               if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+               if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                        switch_core_session_t *session;
                        if ((session = switch_core_session_locate(uuid))) {
                                switch_channel_t *tchannel = switch_core_session_get_channel(session);
@@ -896,7 +896,7 @@ SWITCH_DECLARE(void *) switch_channel_get_private_partner(switch_channel_t *chan
 
        switch_assert(channel != NULL);
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                switch_core_session_t *session;
                if ((session = switch_core_session_locate(uuid))) {
                        val = switch_core_hash_find_locked(channel->private_hash, key, channel->profile_mutex);
@@ -1292,7 +1292,7 @@ SWITCH_DECLARE(switch_status_t) switch_channel_set_variable_partner_var_check(sw
        switch_assert(channel != NULL);
 
        if (!zstr(varname)) {
-               if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+               if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                        switch_core_session_t *session;
                        if ((session = switch_core_session_locate(uuid))) {
                                switch_channel_t *tchannel = switch_core_session_get_channel(session);
@@ -1325,7 +1325,7 @@ SWITCH_DECLARE(switch_bool_t) switch_channel_set_flag_partner(switch_channel_t *
 
        switch_assert(channel != NULL);
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                switch_core_session_t *session;
                if ((session = switch_core_session_locate(uuid))) {
                        switch_channel_set_flag(switch_core_session_get_channel(session), flag);
@@ -1344,7 +1344,7 @@ SWITCH_DECLARE(uint32_t) switch_channel_test_flag_partner(switch_channel_t *chan
 
        switch_assert(channel != NULL);
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                switch_core_session_t *session;
                if ((session = switch_core_session_locate(uuid))) {
                        r = switch_channel_test_flag(switch_core_session_get_channel(session), flag);
@@ -1361,7 +1361,7 @@ SWITCH_DECLARE(switch_bool_t) switch_channel_clear_flag_partner(switch_channel_t
 
        switch_assert(channel != NULL);
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                switch_core_session_t *session;
                if ((session = switch_core_session_locate(uuid))) {
                        switch_channel_clear_flag(switch_core_session_get_channel(session), flag);
@@ -1479,7 +1479,7 @@ SWITCH_DECLARE(uint32_t) switch_channel_test_cap_partner(switch_channel_t *chann
 
        switch_assert(channel != NULL);
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) {
                switch_core_session_t *session;
                if ((session = switch_core_session_locate(uuid))) {
                        r = switch_channel_test_cap(switch_core_session_get_channel(session), cap);
index f0941297b20e0de1f3fedf68bc8d6cdc6cddfc3c..427eb64eb09bd60daa077c83629ff60735c3305b 100644 (file)
@@ -184,7 +184,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_get_partner(switch_core_sess
 {
        const char *uuid;
 
-       if ((uuid = switch_channel_get_variable(session->channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
+       if ((uuid = switch_channel_get_variable(session->channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(session->channel, "originate_signal_bond"))) {
                if ((*partner = switch_core_session_locate(uuid))) {
                        return SWITCH_STATUS_SUCCESS;
                }
@@ -751,7 +751,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_pass_indication(switch_core_
        switch_channel_t *channel = switch_core_session_get_channel(session);
        switch_status_t status = SWITCH_STATUS_SUCCESS;
 
-       if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) && (other_session = switch_core_session_locate(uuid))) {
+       if (((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE)) || (uuid = switch_channel_get_variable(channel, "originate_signal_bond"))) && (other_session = switch_core_session_locate(uuid))) {
                msg.message_id = indication;
                msg.from = __FILE__;
                status = switch_core_session_receive_message(other_session, &msg);