rust/hedgewars-server/src/main.rs
changeset 14800 f43ab2bd76ae
parent 14712 2071da901c63
child 14804 b3adc030104b
--- a/rust/hedgewars-server/src/main.rs	Tue Apr 09 00:45:14 2019 +0200
+++ b/rust/hedgewars-server/src/main.rs	Tue Apr 09 21:08:35 2019 +0300
@@ -40,13 +40,16 @@
         for event in events.iter() {
             if event.readiness() & Ready::readable() == Ready::readable() {
                 match event.token() {
-                    utils::SERVER => hw_network.accept_client(&poll).unwrap(),
+                    utils::SERVER_TOKEN => hw_network.accept_client(&poll).unwrap(),
+                    #[cfg(feature = "official-server")]
+                    utils::IO_TOKEN => hw_network.handle_io_result(),
                     Token(tok) => hw_network.client_readable(&poll, tok).unwrap(),
                 }
             }
             if event.readiness() & Ready::writable() == Ready::writable() {
                 match event.token() {
-                    utils::SERVER => unreachable!(),
+                    utils::SERVER_TOKEN => unreachable!(),
+                    utils::IO_TOKEN => unreachable!(),
                     Token(tok) => hw_network.client_writable(&poll, tok).unwrap(),
                 }
             }