Skip to content

Commit

Permalink
Remove comment about code-stench
Browse files Browse the repository at this point in the history
Since all callbacks into swift are done on a new thread, tokio will no
longer crash when Swift tries to cancel futures.
  • Loading branch information
pinkisemils committed Dec 13, 2024
1 parent af5b003 commit c962051
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions mullvad-ios/src/ephemeral_peer_proxy/peer_exchange.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ impl ExchangeCancelToken {
if let Ok(mut inner) = self.inner.lock() {
if let Some(task) = inner.task.take() {
task.abort();
// CODE STENCH:
// Swift can call this function from a tokio context. That *will* crash.
let _ = inner.tokio_handle.block_on(task);
}
}
Expand Down

0 comments on commit c962051

Please sign in to comment.