diff --git a/crates/net/network/src/session/active.rs b/crates/net/network/src/session/active.rs index f59055f84c..874364374b 100644 --- a/crates/net/network/src/session/active.rs +++ b/crates/net/network/src/session/active.rs @@ -97,7 +97,7 @@ pub(crate) struct ActiveSession { /// A message that needs to be delivered to the session manager pub(crate) pending_message_to_session: Option>, /// Incoming internal requests which are delegated to the remote peer. - pub(crate) internal_request_tx: Fuse>>, + pub(crate) internal_request_rx: Fuse>>, /// All requests sent to the remote peer we're waiting on a response pub(crate) inflight_requests: FxHashMap>>, /// All requests that were sent by the remote peer and we're waiting on an internal response @@ -547,7 +547,7 @@ impl Future for ActiveSession { let deadline = this.request_deadline(); - while let Poll::Ready(Some(req)) = this.internal_request_tx.poll_next_unpin(cx) { + while let Poll::Ready(Some(req)) = this.internal_request_rx.poll_next_unpin(cx) { progress = true; this.on_internal_peer_request(req, deadline); } @@ -960,7 +960,7 @@ mod tests { "network_active_session", ), pending_message_to_session: None, - internal_request_tx: ReceiverStream::new(messages_rx).fuse(), + internal_request_rx: ReceiverStream::new(messages_rx).fuse(), inflight_requests: Default::default(), conn, queued_outgoing: QueuedOutgoingMessages::new(Gauge::noop()), diff --git a/crates/net/network/src/session/mod.rs b/crates/net/network/src/session/mod.rs index d0da757ec6..08c5d7b5d9 100644 --- a/crates/net/network/src/session/mod.rs +++ b/crates/net/network/src/session/mod.rs @@ -521,7 +521,7 @@ impl SessionManager { commands_rx: ReceiverStream::new(commands_rx), to_session_manager: self.active_session_tx.clone(), pending_message_to_session: None, - internal_request_tx: ReceiverStream::new(messages_rx).fuse(), + internal_request_rx: ReceiverStream::new(messages_rx).fuse(), inflight_requests: Default::default(), conn, queued_outgoing: QueuedOutgoingMessages::new(