mirror of
https://github.com/ntex-rs/ntex.git
synced 2025-04-05 05:47:40 +03:00
fix wake write method dsp_restart_write_task
This commit is contained in:
parent
5f7b2b0eae
commit
00df8452f3
3 changed files with 6 additions and 13 deletions
|
@ -1,5 +1,9 @@
|
||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
|
## [0.2.0-b.11] - 2021-02-02
|
||||||
|
|
||||||
|
* framed: fix wake write method dsp_restart_write_task
|
||||||
|
|
||||||
## [0.2.0-b.10] - 2021-01-28
|
## [0.2.0-b.10] - 2021-01-28
|
||||||
|
|
||||||
* framed: Allow to wake up write io task
|
* framed: Allow to wake up write io task
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "ntex"
|
name = "ntex"
|
||||||
version = "0.2.0-b.10"
|
version = "0.2.0-b.11"
|
||||||
authors = ["ntex contributors <team@ntex.rs>"]
|
authors = ["ntex contributors <team@ntex.rs>"]
|
||||||
description = "Framework for composable network services"
|
description = "Framework for composable network services"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
|
|
@ -349,19 +349,8 @@ impl State {
|
||||||
#[inline]
|
#[inline]
|
||||||
/// Wake write io task
|
/// Wake write io task
|
||||||
pub fn dsp_restart_write_task(&self) {
|
pub fn dsp_restart_write_task(&self) {
|
||||||
// if write buffer is empty then write task is asleep
|
|
||||||
// otherwise write task is active
|
|
||||||
if self.0.write_buf.borrow().is_empty() {
|
|
||||||
self.0.write_task.wake();
|
self.0.write_task.wake();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
#[inline]
|
|
||||||
/// Wake write io task
|
|
||||||
pub fn dsp_flush_write_data(&self, _: &Waker) {
|
|
||||||
self.dsp_restart_write_task()
|
|
||||||
}
|
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
/// Wake read io task if it is not ready
|
/// Wake read io task if it is not ready
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue