1
0
Fork 0
mirror of https://gitlab.redox-os.org/CoffeeCode/redox-ssh.git synced 2025-12-28 15:22:18 +01:00

Remove threading for now

This commit is contained in:
Thomas Gatzweiler 2017-07-16 11:08:56 +02:00
parent ba376a9add
commit cf7644a5ed

View file

@ -1,6 +1,5 @@
use std::io::{self, Write};
use std::net::TcpListener;
use std::thread;
use connection::{Connection, ConnectionType};
use packet::Packet;
@ -37,15 +36,12 @@ impl Server {
println!("Incoming connection from {}", addr);
thread::spawn(move || {
let mut connection = Connection::new(
ConnectionType::Server,
stream.try_clone().unwrap(),
);
connection.run(&mut stream);
});
let mut connection = Connection::new(
ConnectionType::Server,
stream.try_clone().unwrap(),
);
connection.run(&mut stream);
}
Ok(())