mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-02-08 08:51:50 +00:00
minor adj
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4106 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
59ed99a9a8
commit
ea0a65d5ff
@ -757,7 +757,7 @@ static int activate_rtp(struct private_object *tech_pvt)
|
|||||||
tech_pvt->remote_ip,
|
tech_pvt->remote_ip,
|
||||||
tech_pvt->remote_port,
|
tech_pvt->remote_port,
|
||||||
tech_pvt->codec_num,
|
tech_pvt->codec_num,
|
||||||
0,
|
tech_pvt->read_codec.implementation->encoded_bytes_per_frame,
|
||||||
tech_pvt->read_codec.implementation->microseconds_per_frame,
|
tech_pvt->read_codec.implementation->microseconds_per_frame,
|
||||||
flags,
|
flags,
|
||||||
NULL,
|
NULL,
|
||||||
@ -1527,6 +1527,7 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session,
|
|||||||
|
|
||||||
switch_copy_string(workspace, outbound_profile->destination_number, sizeof(workspace));
|
switch_copy_string(workspace, outbound_profile->destination_number, sizeof(workspace));
|
||||||
profile_name = workspace;
|
profile_name = workspace;
|
||||||
|
|
||||||
if ((callto = strchr(profile_name, '/'))) {
|
if ((callto = strchr(profile_name, '/'))) {
|
||||||
*callto++ = '\0';
|
*callto++ = '\0';
|
||||||
} else {
|
} else {
|
||||||
@ -1539,6 +1540,9 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session,
|
|||||||
*dnis++ = '\0';
|
*dnis++ = '\0';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (p = callto; p && *p; p++) {
|
||||||
|
*p = (char) tolower(*p);
|
||||||
|
}
|
||||||
|
|
||||||
if ((p = strchr(profile_name, '@'))) {
|
if ((p = strchr(profile_name, '@'))) {
|
||||||
*p++ = '\0';
|
*p++ = '\0';
|
||||||
@ -1623,9 +1627,9 @@ static switch_status_t channel_outgoing_channel(switch_core_session_t *session,
|
|||||||
ldl_session_create(&dlsession, mdl_profile->handle, sess_id, full_id, user, LDL_FLAG_OUTBOUND);
|
ldl_session_create(&dlsession, mdl_profile->handle, sess_id, full_id, user, LDL_FLAG_OUTBOUND);
|
||||||
tech_pvt->profile = mdl_profile;
|
tech_pvt->profile = mdl_profile;
|
||||||
ldl_session_set_private(dlsession, *new_session);
|
ldl_session_set_private(dlsession, *new_session);
|
||||||
//ldl_session_set_value(dlsession, "dnis", dnis);
|
ldl_session_set_value(dlsession, "dnis", dnis);
|
||||||
//ldl_session_set_value(dlsession, "caller_id_name", outbound_profile->caller_id_name);
|
ldl_session_set_value(dlsession, "caller_id_name", outbound_profile->caller_id_name);
|
||||||
//ldl_session_set_value(dlsession, "caller_id_number", outbound_profile->caller_id_number);
|
ldl_session_set_value(dlsession, "caller_id_number", outbound_profile->caller_id_number);
|
||||||
tech_pvt->dlsession = dlsession;
|
tech_pvt->dlsession = dlsession;
|
||||||
if (!get_codecs(tech_pvt)) {
|
if (!get_codecs(tech_pvt)) {
|
||||||
terminate_session(new_session, __LINE__, SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER);
|
terminate_session(new_session, __LINE__, SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER);
|
||||||
|
@ -758,9 +758,10 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_
|
|||||||
bytes = sbytes;
|
bytes = sbytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bytes > 0) {
|
if (bytes > 0 && rtp_session->recv_msg.header.version == 2) {
|
||||||
uint32_t effective_size = (uint32_t)(bytes - rtp_header_len);
|
uint32_t effective_size = (uint32_t)(bytes - rtp_header_len);
|
||||||
if (rtp_session->recv_msg.header.pt == rtp_session->payload && effective_size != rtp_session->packet_size) {
|
if (effective_size && rtp_session->packet_size && rtp_session->recv_msg.header.pt == rtp_session->payload &&
|
||||||
|
effective_size != rtp_session->packet_size) {
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Configured packet size %u != inbound packet size %u: auto-correcting..\n",
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Configured packet size %u != inbound packet size %u: auto-correcting..\n",
|
||||||
rtp_session->packet_size,
|
rtp_session->packet_size,
|
||||||
effective_size
|
effective_size
|
||||||
|
Loading…
x
Reference in New Issue
Block a user