Skip to content

Commit b2ca545

Browse files
committed
minimize spurious wakeups
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
1 parent cd81196 commit b2ca545

File tree

1 file changed

+0
-4
lines changed
  • crates/wasi-tls/src/p3/host

1 file changed

+0
-4
lines changed

crates/wasi-tls/src/p3/host/mod.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ where
132132
conn,
133133
ciphertext_consumer,
134134
ciphertext_producer,
135-
plaintext_consumer,
136135
plaintext_producer,
137136
..
138137
} = stream.as_deref_mut().unwrap();
@@ -157,15 +156,12 @@ where
157156
Err(err) => {
158157
_ = error_tx.take().unwrap().send(format!("{err}"));
159158
ciphertext_producer.take().map(Waker::wake);
160-
plaintext_consumer.take().map(Waker::wake);
161-
plaintext_producer.take().map(Waker::wake);
162159
return Poll::Ready(Ok(StreamResult::Dropped));
163160
}
164161
};
165162
if state.plaintext_bytes_to_read() > 0 {
166163
plaintext_producer.take().map(Waker::wake);
167164
}
168-
169165
if state.tls_bytes_to_write() > 0 {
170166
ciphertext_producer.take().map(Waker::wake);
171167
}

0 commit comments

Comments
 (0)