mirror of
https://github.com/tun2proxy/tun2proxy.git
synced 2025-04-19 21:39:09 +00:00
parent
41c22fa4d4
commit
be3d7e314b
1 changed files with 50 additions and 49 deletions
|
@ -439,8 +439,8 @@ impl<'a> TunToProxy<'a> {
|
|||
}
|
||||
|
||||
fn mio_socket_event(&mut self, event: &Event) {
|
||||
let connection = *self.token_to_connection.get(&event.token()).unwrap();
|
||||
|
||||
if let Some(conn_ref) = self.token_to_connection.get(&event.token()) {
|
||||
let connection = *conn_ref;
|
||||
if event.is_readable() {
|
||||
{
|
||||
let state = self.connections.get_mut(&connection).unwrap();
|
||||
|
@ -496,6 +496,7 @@ impl<'a> TunToProxy<'a> {
|
|||
self.write_to_server(&connection);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn udp_event(&mut self, _event: &Event) {}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue