rust/hedgewars-server/src/server/network.rs
changeset 14868 eef1f76150fe
parent 14856 57ed3981db20
child 14891 ce98c37826a7
equal deleted inserted replaced
14867:75b515a64202 14868:eef1f76150fe
   479         }
   479         }
   480     }
   480     }
   481 
   481 
   482     fn init_client(&mut self, poll: &Poll, client_id: ClientId) {
   482     fn init_client(&mut self, poll: &Poll, client_id: ClientId) {
   483         let mut response = handlers::Response::new(client_id);
   483         let mut response = handlers::Response::new(client_id);
   484         #[cfg(feature = "tls-connections")]
   484 
   485         response.add(Redirect(self.ssl.listener.local_addr().unwrap().port()).send_self());
   485         if let ClientSocket::Plain(_) = self.clients[client_id].socket {
       
   486             #[cfg(feature = "tls-connections")]
       
   487             response.add(Redirect(self.ssl.listener.local_addr().unwrap().port()).send_self())
       
   488         }
   486 
   489 
   487         handlers::handle_client_accept(&mut self.server, client_id, &mut response);
   490         handlers::handle_client_accept(&mut self.server, client_id, &mut response);
   488         self.handle_response(response, poll);
   491         self.handle_response(response, poll);
   489     }
   492     }
   490 
   493