mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-10-19 09:44:13 +00:00
Merge branch 'master' of ssh://git.freeswitch.org:222/freeswitch
This commit is contained in:
commit
07d202d50f
24 files changed
+367
-88
No files matched your search
@@ -802,15 +802,20 @@ static switch_status_t loopback_bowout_on_execute_state_handler(switch_core_sess
|
||||
switch_core_session_read_lock(tech_pvt->other_session);
|
||||
b_channel = switch_core_session_get_channel(tech_pvt->other_session);
|
||||
|
||||
/* Wait for b_channel to be fully bridged */
|
||||
switch_channel_wait_for_flag(b_channel, CF_BRIDGED, SWITCH_TRUE, 5000, NULL);
|
||||
|
||||
uuid = switch_channel_get_variable(b_channel, SWITCH_SIGNAL_BOND_VARIABLE);
|
||||
|
||||
if (uuid && (other_session = switch_core_session_locate(uuid))) {
|
||||
switch_channel_t *other_channel = switch_core_session_get_channel(other_session);
|
||||
switch_caller_profile_t *cp, *clone;
|
||||
|
||||
|
||||
switch_channel_wait_for_state(other_channel, NULL, CS_EXCHANGE_MEDIA);
|
||||
|
||||
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->other_session), SWITCH_LOG_INFO, "Replacing loopback channel: %s with real channel: %s\n",
|
||||
switch_channel_get_name(b_channel), switch_channel_get_name(other_channel));
|
||||
|
||||
|
||||
if ((cp = switch_channel_get_caller_profile(channel))) {
|
||||
clone = switch_caller_profile_clone(other_session, cp);
|
||||
clone->originator_caller_profile = NULL;
|
||||
@@ -831,7 +836,7 @@ static switch_status_t loopback_bowout_on_execute_state_handler(switch_core_sess
|
||||
switch_core_session_rwunlock(tech_pvt->other_session);
|
||||
|
||||
switch_core_event_hook_remove_state_change(session, loopback_bowout_on_execute_state_handler);
|
||||
|
||||
|
||||
}
|
||||
return SWITCH_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -1324,7 +1324,6 @@ SWITCH_MODULE_LOAD_FUNCTION(mod_portaudio_load)
|
||||
globals.read_frame.buflen = sizeof(globals.databuf);
|
||||
globals.cng_frame.data = globals.cngbuf;
|
||||
globals.cng_frame.buflen = sizeof(globals.cngbuf);
|
||||
globals.cng_frame.datalen = switch_samples_per_packet(globals.sample_rate, globals.codec_ms) * 2;
|
||||
switch_set_flag((&globals.cng_frame), SFF_CNG);
|
||||
globals.flags = GFLAG_EAR | GFLAG_MOUTH;
|
||||
/* dual streams makes portaudio on solaris choke */
|
||||
@@ -1750,6 +1749,8 @@ static switch_status_t load_config(void)
|
||||
globals.codec_ms = 20;
|
||||
}
|
||||
|
||||
globals.cng_frame.datalen = switch_samples_per_packet(globals.sample_rate, globals.codec_ms) * 2;
|
||||
|
||||
if (!globals.ring_interval) {
|
||||
globals.ring_interval = 5;
|
||||
}
|
||||
|
||||
@@ -321,7 +321,7 @@ typedef enum {
|
||||
TFLAG_MAX
|
||||
} TFLAGS;
|
||||
|
||||
#define SOFIA_MAX_MSG_QUEUE 51
|
||||
#define SOFIA_MAX_MSG_QUEUE 101
|
||||
#define SOFIA_MSG_QUEUE_SIZE 5000
|
||||
|
||||
struct mod_sofia_globals {
|
||||
|
||||
@@ -1145,6 +1145,7 @@ void *SWITCH_THREAD_FUNC sofia_msg_thread_run(switch_thread_t *thread, void *obj
|
||||
while(switch_queue_pop(q, &pop) == SWITCH_STATUS_SUCCESS && pop) {
|
||||
sofia_dispatch_event_t *de = (sofia_dispatch_event_t *) pop;
|
||||
sofia_process_dispatch_event(&de);
|
||||
switch_cond_next();
|
||||
}
|
||||
|
||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "MSG Thread Ended\n");
|
||||
@@ -1175,7 +1176,7 @@ static void sofia_msg_thread_start(int idx)
|
||||
|
||||
switch_threadattr_create(&thd_attr, mod_sofia_globals.pool);
|
||||
switch_threadattr_stacksize_set(thd_attr, SWITCH_THREAD_STACKSIZE);
|
||||
switch_threadattr_priority_increase(thd_attr);
|
||||
//switch_threadattr_priority_increase(thd_attr);
|
||||
switch_thread_create(&mod_sofia_globals.msg_queue_thread[i],
|
||||
thd_attr,
|
||||
sofia_msg_thread_run,
|
||||
|
||||
Reference in new issue
Block a user