Skip to content

Commit

Permalink
frames: avoid references to pinky
Browse files Browse the repository at this point in the history
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
  • Loading branch information
Keruspe committed Jul 16, 2024
1 parent 871558a commit e480f23
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/frames.rs
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ impl Inner {
while let Some(reply) = expected_replies.pop_front() {
match &reply.0 {
Reply::ChannelCloseOk(_) => return Some(reply.0),
Reply::BasicCancelOk(pinky) => pinky.resolve(()), // Channel close means consumer is canceled automatically
Reply::BasicCancelOk(resolver) => resolver.resolve(()), // Channel close means consumer is canceled automatically
_ => reply.1.cancel(error.clone()),
}
}
Expand All @@ -274,7 +274,7 @@ impl Inner {
fn cancel_expected_replies(replies: VecDeque<ExpectedReply>, error: Error) {
for ExpectedReply(reply, cancel) in replies {
match reply {
Reply::BasicCancelOk(pinky) => pinky.resolve(()),
Reply::BasicCancelOk(resolver) => resolver.resolve(()),
_ => cancel.cancel(error.clone()),
}
}
Expand Down

0 comments on commit e480f23

Please sign in to comment.