From 649997088bffab90cd243d635b95756d11678e51 Mon Sep 17 00:00:00 2001 From: ENGO150 Date: Thu, 9 Feb 2023 19:32:54 +0100 Subject: [PATCH] fixed server loop --- src/chat/server/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/chat/server/main.c b/src/chat/server/main.c index 7e03f28..843364e 100644 --- a/src/chat/server/main.c +++ b/src/chat/server/main.c @@ -41,7 +41,7 @@ int main(void) if (listen(listen_socket, 1) < 0) why2_die("Binding failed."); //LOOP ACCEPT - while (getchar() != '\n') //END WHEN ENTER IS PRESSED + for (;;) { accepted = accept(listen_socket, (SA *) NULL, NULL); //ACCEPT NEW SOCKET //TODO: CLOSE