ok find stangor

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15674 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale 2009-11-25 21:34:51 +00:00
parent 77933de4f0
commit 6daa81d7b8
1 changed files with 8 additions and 4 deletions

View File

@ -413,10 +413,14 @@ const char *sofia_glue_get_codec_string(private_object_t *tech_pvt)
{
const char *codec_string = NULL;
if (switch_channel_direction(tech_pvt->channel) == SWITCH_CALL_DIRECTION_OUTBOUND && !zstr(tech_pvt->profile->outbound_codec_string)) {
codec_string = tech_pvt->profile->outbound_codec_string ? tech_pvt->profile->outbound_codec_string : tech_pvt->profile->inbound_codec_string;
} else if (!zstr(tech_pvt->profile->inbound_codec_string)) {
codec_string = tech_pvt->profile->inbound_codec_string ? tech_pvt->profile->inbound_codec_string : tech_pvt->profile->outbound_codec_string;
if (switch_channel_direction(tech_pvt->channel) == SWITCH_CALL_DIRECTION_OUTBOUND) {
if (!zstr(tech_pvt->profile->outbound_codec_string)) {
codec_string = tech_pvt->profile->outbound_codec_string ? tech_pvt->profile->outbound_codec_string : tech_pvt->profile->inbound_codec_string;
}
} else {
if (!zstr(tech_pvt->profile->inbound_codec_string)) {
codec_string = tech_pvt->profile->inbound_codec_string ? tech_pvt->profile->inbound_codec_string : tech_pvt->profile->outbound_codec_string;
}
}
return codec_string;