From 6a9a0710b695da4f67f4e0939245a78ca2715e2a Mon Sep 17 00:00:00 2001 From: Benjamin Valentin Date: Fri, 2 Feb 2024 11:48:54 +0100 Subject: [PATCH] sys/net/telnet: properly detect disconnect --- sys/net/application_layer/telnet/telnet_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/application_layer/telnet/telnet_server.c b/sys/net/application_layer/telnet/telnet_server.c index 6f0528580ba18..7bacf70acc82e 100644 --- a/sys/net/application_layer/telnet/telnet_server.c +++ b/sys/net/application_layer/telnet/telnet_server.c @@ -227,7 +227,7 @@ static void *telnet_thread(void *arg) continue; } - if (res < 0) { + if (res <= 0) { break; }