提交 524468be authored 作者: Anthony Minessale's avatar Anthony Minessale

FS-4373 --resolve this is probably the same issue nobody would file a bug about…

FS-4373 --resolve this is probably the same issue nobody would file a bug about on the mailing list even after I begged them to from last weekend
上级 bd66d7ea
......@@ -1682,7 +1682,7 @@ static void setup_codecs(struct private_object *tech_pvt)
}
if (!payloads[1].id) {
if (!payloads[1].id && tech_pvt->transports[LDL_TPORT_VIDEO_RTP].local_port) {
switch_rtp_release_port(tech_pvt->profile->ip, tech_pvt->transports[LDL_TPORT_VIDEO_RTP].local_port);
tech_pvt->transports[LDL_TPORT_VIDEO_RTP].local_port = 0;
}
......@@ -2846,7 +2846,7 @@ static void set_profile_val(mdl_profile_t *profile, char *var, char *val)
} else if (val && !strcasecmp(val, "md5")) {
profile->user_flags |= LDL_FLAG_SASL_MD5;
}
} else if (!strcasecmp(var, "use-jingle") && !zstr(val)) {
} else if (!strcasecmp(var, "use-jingle") && switch_true(val)) {
profile->user_flags |= LDL_FLAG_JINGLE;
} else if (!strcasecmp(var, "exten") && !zstr(val)) {
profile->exten = switch_core_strdup(module_pool, val);
......
......@@ -174,7 +174,13 @@ SWITCH_DECLARE(switch_status_t) switch_core_port_allocator_free_port(switch_core
switch_status_t status = SWITCH_STATUS_FALSE;
int even = switch_test_flag(alloc, SPF_EVEN);
int odd = switch_test_flag(alloc, SPF_ODD);
int index = port - alloc->start;
int index;
if (port < alloc->start) {
return SWITCH_STATUS_GENERR;
}
index = port - alloc->start;
if (!(even && odd)) {
index /= 2;
......
......@@ -1229,7 +1229,7 @@ SWITCH_DECLARE(void) switch_rtp_release_port(const char *ip, switch_port_t port)
{
switch_core_port_allocator_t *alloc = NULL;
if (!ip) {
if (!ip || !port) {
return;
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论