master
rasul 5 years ago
parent cb703cf988
commit 96f623584a

@ -38,12 +38,11 @@ impl Game {
let poll = try_log!(Poll::new(), "Unable to create Poll");
try_log!(
poll.registry().register(&mut server.socket, Token(0), Interest::READABLE),
poll.registry()
.register(&mut server.socket, Token(0), Interest::READABLE),
"Unable to register poll"
);
debug!("Accepting connections");
Ok(Self {

@ -3,9 +3,9 @@
use std::io;
use std::net::SocketAddr;
use mio::{Interest, Registry, Token};
use mio::event::Source;
use mio::net::TcpListener;
use mio::{Interest, Registry, Token};
use crate::client::Client;
use crate::result::*;
@ -60,7 +60,7 @@ impl Source for Server {
&mut self,
registry: &Registry,
token: Token,
interest: Interest
interest: Interest,
) -> io::Result<()> {
self.socket.register(registry, token, interest)
}

Loading…
Cancel
Save