mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-11-16 14:28:34 +00:00
add more range to saved candidates and fix off-by-one error when total is met
This commit is contained in:
1 parent
4e6852fd88
commit
ae99177598
2 files changed
+3
-3
No files matched your search
@@ -2332,6 +2332,8 @@ static void check_ice(switch_media_handle_t *smh, switch_media_type_t type, sdp_
|
||||
data = switch_core_session_strdup(smh->session, attr->a_value);
|
||||
|
||||
argc = switch_split(data, ' ', fields);
|
||||
|
||||
engine->ice_in.cand_idx++;
|
||||
|
||||
if (argc < 5 || engine->ice_in.cand_idx >= MAX_CAND) {
|
||||
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(smh->session), SWITCH_LOG_WARNING, "Invalid data\n");
|
||||
@@ -2349,8 +2351,6 @@ static void check_ice(switch_media_handle_t *smh, switch_media_type_t type, sdp_
|
||||
"Checking Candidate cid: %d proto: %s type: %s addr: %s:%s\n", cid+1, fields[2], fields[7], fields[4], fields[5]);
|
||||
|
||||
|
||||
engine->ice_in.cand_idx++;
|
||||
|
||||
for (i = 0; i < engine->cand_acl_count; i++) {
|
||||
if (!engine->ice_in.chosen[cid] && switch_check_network_list_ip(fields[4], engine->cand_acl[i])) {
|
||||
engine->ice_in.chosen[cid] = engine->ice_in.cand_idx;
|
||||
|
||||
Reference in new issue
Block a user