FSCORE-240

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@10559 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale 2008-12-01 16:21:27 +00:00
parent 8719823f5d
commit cb5096db71
3 changed files with 17 additions and 7 deletions

View File

@ -441,6 +441,7 @@ static const char *message_names[] = {
"SWITCH_MESSAGE_INDICATE_VIDEO_REFRESH_REQ",
"SWITCH_MESSAGE_INDICATE_DISPLAY",
"SWITCH_MESSAGE_INDICATE_TRANSCODING_NECESSARY",
"SWITCH_MESSAGE_INDICATE_AUDIO_SYNC",
"SWITCH_MESSAGE_INVALID"
};

View File

@ -52,7 +52,13 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_sleep(switch_core_session_t *session,
cng_frame.buflen = 2;
switch_set_flag((&cng_frame), SFF_CNG);
switch_channel_audio_sync(channel);
if (!switch_channel_test_flag(channel, CF_PROXY_MODE)) {
switch_channel_audio_sync(channel);
}
if (!ms) {
return SWITCH_STATUS_SUCCESS;
}
for (;;) {
now = switch_timestamp_now();

View File

@ -39,12 +39,6 @@ static switch_status_t originate_on_consume_media_transmit(switch_core_session_t
{
switch_channel_t *channel = switch_core_session_get_channel(session);
if (!switch_channel_test_flag(channel, CF_PROXY_MODE)) {
while (switch_channel_get_state(channel) == CS_CONSUME_MEDIA && !switch_channel_test_flag(channel, CF_TAGGED)) {
switch_ivr_sleep(session, 10, NULL);
}
}
switch_channel_clear_state_handler(channel, &originate_state_handlers);
return SWITCH_STATUS_FALSE;
@ -97,6 +91,8 @@ static void *SWITCH_THREAD_FUNC collect_thread_run(switch_thread_t *thread, void
return NULL;
}
switch_ivr_sleep(collect->session, 0, NULL);
if (!strcasecmp(collect->key, "exec")) {
char *data;
switch_application_interface_t *application_interface;
@ -1680,6 +1676,13 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_originate(switch_core_session_t *sess
*bleg = NULL;
}
if (*bleg) {
switch_ivr_sleep(*bleg, 0, NULL);
}
if (session) {
switch_ivr_sleep(session, 0, NULL);
}
if (var_event) {
switch_event_destroy(&var_event);