From 62b4d2478f440eeb48b9a704da2c656a83bb7d51 Mon Sep 17 00:00:00 2001 From: achemin1 Date: Mon, 25 Jan 2021 18:56:16 +0100 Subject: [PATCH] add : pong from the server --- server.c | 5 +++++ 1 file changed, 5 insertions(+), 0 deletions(-) diff --git a/server.c b/server.c index 2a31787..58f23bf 100644 --- a/server.c +++ b/server.c @@ -170,6 +170,11 @@ int boucleServeur2(int ecoute) fgets(ligne,MAX_LIGNE,f); printf(">%i$ %s\n", i+1, ligne); + //renvoyer à tous les clients + for(int j = 0 ; j < LongueurPoll-1 ; j++){ + if(j != i) + dprintf(descripteurs[j+1].fd, ":%s\n", ligne); + } } } -- libgit2 0.21.2