diff --git a/rust/Cargo.lock b/rust/Cargo.lock index 33363aac6..9c12554b1 100644 --- a/rust/Cargo.lock +++ b/rust/Cargo.lock @@ -6597,7 +6597,7 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "str0m" version = "0.8.0" -source = "git+https://github.com/firezone/str0m?branch=main#8401a07556ee930866768d3993514fedb455b0b3" +source = "git+https://github.com/algesten/str0m?branch=main#6025dfde2e48905539255ec88f1350ab50428d50" dependencies = [ "combine", "crc", diff --git a/rust/Cargo.toml b/rust/Cargo.toml index f8cfd59a9..8b8b966b4 100644 --- a/rust/Cargo.toml +++ b/rust/Cargo.toml @@ -215,7 +215,7 @@ ip_network = { git = "https://github.com/JakubOnderka/ip_network", branch = "mas ip_network_table = { git = "https://github.com/edmonds/ip_network_table", branch = "some-useful-traits" } # For `Debug` and `Clone` tracing-stackdriver = { git = "https://github.com/thomaseizinger/tracing-stackdriver", branch = "bump-otel-0.26" } # Waiting for release. softbuffer = { git = "https://github.com/rust-windowing/softbuffer" } # Waiting for release. -str0m = { git = "https://github.com/firezone/str0m", branch = "main" } +str0m = { git = "https://github.com/algesten/str0m", branch = "main" } # Enforce `tracing-macros` to have released `tracing` version. [patch.'https://github.com/tokio-rs/tracing'] diff --git a/rust/connlib/snownet/src/node.rs b/rust/connlib/snownet/src/node.rs index 8bdfd60c5..0bb24aef8 100644 --- a/rust/connlib/snownet/src/node.rs +++ b/rust/connlib/snownet/src/node.rs @@ -1387,14 +1387,14 @@ fn add_local_candidate( return; } - let is_new = agent.add_local_candidate(candidate.clone()); + let Some(candidate) = agent.add_local_candidate(candidate) else { + return; + }; - if is_new { - pending_events.push_back(Event::NewIceCandidate { - connection: id, - candidate: candidate.to_sdp_string(), - }) - } + pending_events.push_back(Event::NewIceCandidate { + connection: id, + candidate: candidate.to_sdp_string(), + }) } fn invalidate_allocation_candidates(