mirror of
https://github.com/tokio-rs/tokio.git
synced 2025-10-01 12:20:39 +00:00
signal: Don't use the depreceated new method of Registration
This commit is contained in:
parent
484fda7a23
commit
9a4e4f2308
@ -324,7 +324,8 @@ impl mio::Evented for MyRegistration {
|
|||||||
events: mio::Ready,
|
events: mio::Ready,
|
||||||
opts: mio::PollOpt,
|
opts: mio::PollOpt,
|
||||||
) -> io::Result<()> {
|
) -> io::Result<()> {
|
||||||
let reg = mio::Registration::new(poll, token, events, opts);
|
let reg = mio::Registration::new2();
|
||||||
|
reg.0.register(poll, token, events, opts)?;
|
||||||
*self.inner.borrow_mut() = Some(reg);
|
*self.inner.borrow_mut() = Some(reg);
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user