2024-04-13 13:28:50 +03:00
|
|
|
use std::net;
|
|
|
|
use pasternakd::handle_client;
|
|
|
|
|
|
|
|
fn main() {
|
2024-04-14 11:47:49 +03:00
|
|
|
let listener = net::TcpListener::bind("0.0.0.0:8492")
|
2024-04-13 13:28:50 +03:00
|
|
|
.expect("Failed to listen on port 8492");
|
|
|
|
|
2024-04-13 14:31:21 +03:00
|
|
|
println!("Listening on port 8492");
|
|
|
|
|
2024-04-13 13:28:50 +03:00
|
|
|
for stream in listener.incoming() {
|
2024-04-13 14:31:21 +03:00
|
|
|
println!("Handling Client");
|
2024-04-13 13:28:50 +03:00
|
|
|
handle_client();
|
|
|
|
}
|
|
|
|
|
|
|
|
main();
|
|
|
|
}
|