FS-5513 --resolve

This commit is contained in:
Anthony Minessale 2013-06-18 21:16:48 -05:00
parent a7be251bd8
commit 4baf0276d6
3 changed files with 7 additions and 8 deletions

View File

@ -144,8 +144,6 @@ typedef struct switch_core_media_params_s {
char *sdp_username;
switch_mutex_t *mutex;
switch_payload_t te;
switch_payload_t recv_te;

View File

@ -156,7 +156,6 @@ void sofia_glue_attach_private(switch_core_session_t *session, sofia_profile_t *
tech_pvt->mparams.extsipip = profile->extsipip;
tech_pvt->mparams.extrtpip = profile->extrtpip;
tech_pvt->mparams.local_network = profile->local_network;
tech_pvt->mparams.mutex = tech_pvt->sofia_mutex;
tech_pvt->mparams.sipip = profile->sipip;
tech_pvt->mparams.jb_msec = profile->jb_msec;
tech_pvt->mparams.rtcp_audio_interval_msec = profile->rtcp_audio_interval_msec;

View File

@ -174,7 +174,7 @@ struct switch_media_handle_s {
int payload_space;
char *origin;
switch_mutex_t *mutex;
const switch_codec_implementation_t *negotiated_codecs[SWITCH_MAX_CODECS];
int num_negotiated_codecs;
@ -1036,6 +1036,8 @@ SWITCH_DECLARE(switch_status_t) switch_media_handle_create(switch_media_handle_t
session->media_handle->engines[SWITCH_MEDIA_TYPE_VIDEO].read_frame.buflen = SWITCH_RTP_MAX_BUF_LEN;
session->media_handle->mparams = params;
switch_mutex_init(&session->media_handle->mutex, SWITCH_MUTEX_NESTED, switch_core_session_get_pool(session));
session->media_handle->engines[SWITCH_MEDIA_TYPE_AUDIO].ssrc =
(uint32_t) ((intptr_t) &session->media_handle->engines[SWITCH_MEDIA_TYPE_AUDIO] + (uint32_t) time(NULL));
@ -5022,10 +5024,10 @@ SWITCH_DECLARE(void)switch_core_media_set_local_sdp(switch_core_session_t *sessi
return;
}
if (smh->mparams->mutex) switch_mutex_lock(smh->mparams->mutex);
if (smh->mutex) switch_mutex_lock(smh->mutex);
smh->mparams->local_sdp_str = dup ? switch_core_session_strdup(session, sdp_str) : (char *) sdp_str;
switch_channel_set_variable(session->channel, "rtp_local_sdp_str", smh->mparams->local_sdp_str);
if (smh->mparams->mutex) switch_mutex_unlock(smh->mparams->mutex);
if (smh->mutex) switch_mutex_unlock(smh->mutex);
}
@ -6612,7 +6614,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_media_receive_message(switch_core_se
}
if (smh->mparams->mutex) switch_mutex_lock(smh->mparams->mutex);
if (smh->mutex) switch_mutex_lock(smh->mutex);
if (switch_channel_down(session->channel)) {
@ -6698,7 +6700,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_media_receive_message(switch_core_se
end_lock:
if (smh->mparams->mutex) switch_mutex_unlock(smh->mparams->mutex);
if (smh->mutex) switch_mutex_unlock(smh->mutex);
end: