Skip to content

Commit

Permalink
fix(network/worker): forget response token to prevent recursion on drop
Browse files Browse the repository at this point in the history
  • Loading branch information
Erigara committed Jan 13, 2025
1 parent f86970b commit 98537b5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions elfo-network/src/worker/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,9 @@ impl remote::RemoteHandle for RemoteHandle {
Ok(false) => unreachable!(),
Err(_) => {}
}
} else {
// Forget token to prevent recursion on drop
token.forget();
}

trace!(addr = %recipient, "flow is closed, response is lost");
Expand Down

0 comments on commit 98537b5

Please sign in to comment.