Commit fc0d3744 authored by Olivier Crête's avatar Olivier Crête

agent: Only try to use the address of the same family to connect to TURN

Using a IPv6 local address to connect to a IPv4 relay just creates an
extra discovery attempt that will not provide something useful.
parent c129b05a
......@@ -2456,7 +2456,9 @@ nice_agent_set_relay_info(NiceAgent *agent,
NiceCandidate *candidate = i->data;
if (candidate->type == NICE_CANDIDATE_TYPE_HOST &&
candidate->transport != NICE_CANDIDATE_TRANSPORT_TCP_PASSIVE)
candidate->transport != NICE_CANDIDATE_TRANSPORT_TCP_PASSIVE &&
nice_address_ip_version (&candidate->addr) ==
nice_address_ip_version (&turn->server))
priv_add_new_candidate_discovery_turn (agent,
candidate->sockptr, turn, stream, component_id,
candidate->transport != NICE_CANDIDATE_TRANSPORT_UDP);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment