diff --git a/Cargo.toml b/Cargo.toml index 2269d60..bc223a7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,5 +4,4 @@ version = "0.1.0" edition = "2021" [dependencies] -yaml-rust = "*" -linked-hash-map = "*" \ No newline at end of file +yaml-rust = "*" \ No newline at end of file diff --git a/src/client/mod.rs b/src/client/mod.rs index 467886c..e01842c 100644 --- a/src/client/mod.rs +++ b/src/client/mod.rs @@ -28,7 +28,7 @@ impl<'a> Client<'a> { println!("len_pack {}", self.hs.get_host_name()); } - fn join_conexions_mutex(mut origin: TcpStream, + fn join_conexions(mut origin: TcpStream, mut dest: TcpStream, run: Arc>){ let mut buf: [u8; 200] = [0; 200]; @@ -57,7 +57,7 @@ impl<'a> Client<'a> { let s1 = self.server.try_clone().unwrap(); let r1 = self.run.clone(); let handler1 = thread::spawn( || { - Self::join_conexions_mutex(s1, + Self::join_conexions(s1, c1, r1)} ); @@ -66,7 +66,7 @@ impl<'a> Client<'a> { let s2 = self.server.try_clone().unwrap(); let r2 = self.run.clone(); let handler2 = thread::spawn( || { - Self::join_conexions_mutex(c2, + Self::join_conexions(c2, s2, r2)} );