fix build of actix-server

This commit is contained in:
fakeshadow 2021-02-05 19:51:23 -08:00
parent 38fba7df70
commit 62458f5caf
2 changed files with 1 additions and 5 deletions

View File

@ -505,8 +505,6 @@ impl Future for ServerFuture {
if let Poll::Ready(signal) = Pin::new(signals).poll(cx) {
this.on_stop_task = this.handle_cmd(ServerCommand::Signal(signal));
this.signals = None;
// poll another round for trying on_stop_task.
return self.poll(cx);
}
}

View File

@ -2,8 +2,6 @@ use std::future::Future;
use std::pin::Pin;
use std::task::{Context, Poll};
use crate::server::Server;
/// Different types of process signals
#[allow(dead_code)]
#[derive(PartialEq, Clone, Copy, Debug)]
@ -20,7 +18,7 @@ pub(crate) enum Signal {
pub(crate) struct Signals {
#[cfg(not(unix))]
signals: futures_core::future::LocalBoxFuture<'static, std::io::Result<()>>,
signals: futures_core::future::BoxFuture<'static, std::io::Result<()>>,
#[cfg(unix)]
signals: Vec<(Signal, actix_rt::signal::unix::Signal)>,
}