Skip to content

Commit 0658283

Browse files
committed
wip
1 parent 9f84d45 commit 0658283

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

lib/ex_ice/priv/ice_agent.ex

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1580,8 +1580,9 @@ defmodule ExICE.Priv.ICEAgent do
15801580
{:ok, role_attr} <- get_role_attribute(msg),
15811581
{:ok, use_cand_attr} <- get_use_cand_attribute(msg),
15821582
{:ok, ice_agent} <- check_req_role_conflict(ice_agent, role_attr) do
1583+
# OOOO NIEEEEEE
15831584
{remote_cand, ice_agent} =
1584-
get_or_create_remote_cand(ice_agent, src_ip, src_port, prio_attr)
1585+
get_or_create_remote_cand(ice_agent, local_cand, src_ip, src_port, prio_attr)
15851586

15861587
pair =
15871588
CandidatePair.new(local_cand, remote_cand, ice_agent.role, :waiting, last_seen: now())
@@ -2344,14 +2345,17 @@ defmodule ExICE.Priv.ICEAgent do
23442345
end
23452346
end
23462347

2347-
defp get_or_create_remote_cand(ice_agent, src_ip, src_port, prio_attr) do
2348+
defp get_or_create_remote_cand(ice_agent, local_cand, src_ip, src_port, prio_attr) do
23482349
case find_remote_cand(Map.values(ice_agent.remote_cands), src_ip, src_port) do
23492350
nil ->
2351+
# OOOOO NIEEEEEE
2352+
IO.inspect(local_cand, label: :LOCAL_CANDIDATE)
23502353
cand =
23512354
ExICE.Candidate.new(:prflx,
23522355
address: src_ip,
23532356
port: src_port,
2354-
priority: prio_attr.priority
2357+
priority: prio_attr.priority,
2358+
transport: local_cand.transport
23552359
)
23562360

23572361
Logger.debug("Adding new remote prflx candidate: #{inspect(cand)}")

0 commit comments

Comments
 (0)