Commit a9ac0487 authored by Fabrice Bellet's avatar Fabrice Bellet Committed by Olivier Crête

discovery: ignore all non-relay local candidates when relay is forced

The tcp server reflexive discovered local candidates must be ignored
when force_relay is set.
Reviewed-by: Olivier Crête's avatarOlivier Crête <olivier.crete@collabora.com>
Differential Revision: https://phabricator.freedesktop.org/D1899
parent ea05a3d5
......@@ -688,7 +688,8 @@ discovery_discover_tcp_server_reflexive_candidates (
caddr = c->addr;
nice_address_set_port (&caddr, 0);
if (c->transport != NICE_CANDIDATE_TRANSPORT_UDP &&
if (agent->force_relay == FALSE &&
c->transport != NICE_CANDIDATE_TRANSPORT_UDP &&
c->type == NICE_CANDIDATE_TYPE_HOST &&
nice_address_equal (&base_addr, &caddr)) {
nice_address_set_port (address, nice_address_get_port (&c->addr));
......
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