main: fix socket handling

This commit is contained in:
Astro 2020-03-21 00:37:24 +01:00
parent 7fe1d2f761
commit 15f64358a2
1 changed files with 1 additions and 1 deletions

View File

@ -161,7 +161,7 @@ fn main() -> ! {
// TCP protocol handling
server.for_each(|mut socket, session| {
if ! socket.is_open() {
if ! socket.is_active() {
let _ = socket.listen(TCP_PORT);
session.reset();
} else if socket.can_send() && socket.can_recv() && socket.send_capacity() - socket.send_queue() > 1024 {