Commit 3a58ba61 authored by Fabrice Bellet's avatar Fabrice Bellet
Browse files

conncheck: peer reflexive candidates are not paired

This patch makes the code compliant with ICE RFC, "Learning
Peer Reflexive Candidates" and "Discovering Peer Reflexive
Candidates", where discovered candidates do not cause the creation
of new pairs to be checked.

Differential Revision:
parent 7a2c1edf
......@@ -1787,6 +1787,15 @@ int conn_check_add_for_candidate (NiceAgent *agent, guint stream_id, NiceCompone
g_assert (remote != NULL);
/* note: according to, "Learning Peer Reflexive Candidates",
* the agent does not pair this candidate with any local candidates.
if (agent->compatibility == NICE_COMPATIBILITY_RFC5245 &&
return added;
for (i = component->local_candidates; i ; i = i->next) {
NiceCandidate *local = i->data;
......@@ -1821,6 +1830,18 @@ int conn_check_add_for_local_candidate (NiceAgent *agent, guint stream_id, NiceC
g_assert (local != NULL);
* note: according to "Discovering Peer Reflexive
* Candidates", the peer reflexive candidate is not paired
* with other remote candidates
if (agent->compatibility == NICE_COMPATIBILITY_RFC5245 &&
return added;
for (i = component->remote_candidates; i ; i = i->next) {
NiceCandidate *remote = i->data;
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