mirror of https://github.com/fafhrd91/actix-net
fix build
This commit is contained in:
parent
edb40716a5
commit
b18dd4b05f
|
@ -135,13 +135,6 @@ pub(crate) struct ServerWorker {
|
||||||
shutdown_timeout: Duration,
|
shutdown_timeout: Duration,
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Set worker to unavailable when dropping.
|
|
||||||
impl Drop for ServerWorker {
|
|
||||||
fn drop(&mut self) {
|
|
||||||
self.rx.close();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
struct WorkerService {
|
struct WorkerService {
|
||||||
factory: usize,
|
factory: usize,
|
||||||
status: WorkerServiceStatus,
|
status: WorkerServiceStatus,
|
||||||
|
@ -377,6 +370,9 @@ impl Default for WorkerState {
|
||||||
|
|
||||||
impl Drop for ServerWorker {
|
impl Drop for ServerWorker {
|
||||||
fn drop(&mut self) {
|
fn drop(&mut self) {
|
||||||
|
/// Close channel on drop.
|
||||||
|
self.rx.close();
|
||||||
|
/// Stop Arbiter Self runs on on drop.
|
||||||
Arbiter::current().stop();
|
Arbiter::current().stop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue