mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 09:36:46 +00:00
FSCORE-357
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13285 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
@@ -2056,16 +2056,12 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_originate(switch_core_session_t *sess
|
||||
|
||||
channel = switch_core_session_get_channel(originate_status[i].peer_session);
|
||||
|
||||
switch_channel_wait_for_flag(channel,
|
||||
CF_TIMESTAMP_SET,
|
||||
SWITCH_TRUE,
|
||||
5000,
|
||||
NULL);
|
||||
|
||||
if (!switch_channel_test_flag(channel, CF_TIMESTAMP_SET) || !switch_core_session_running(originate_status[i].peer_session)) {
|
||||
switch_core_session_reporting_state(originate_status[i].peer_session);
|
||||
switch_channel_wait_for_state_timeout(channel, CS_REPORTING, 5000);
|
||||
|
||||
if (!switch_channel_test_flag(channel, CF_TIMESTAMP_SET)) {
|
||||
switch_channel_set_timestamps(channel);
|
||||
}
|
||||
|
||||
|
||||
if (switch_ivr_generate_xml_cdr(originate_status[i].peer_session, &cdr) == SWITCH_STATUS_SUCCESS) {
|
||||
if ((xml_text = switch_xml_toxml(cdr, SWITCH_FALSE))) {
|
||||
switch_snprintf(buf, sizeof(buf), "%s_%d", cdr_var, ++cdr_total);
|
||||
|
Reference in New Issue
Block a user