summaryrefslogtreecommitdiffstats
path: root/tests/echo_srv.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/echo_srv.c')
-rw-r--r--tests/echo_srv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/echo_srv.c b/tests/echo_srv.c
index 771904a..3f8b2a9 100644
--- a/tests/echo_srv.c
+++ b/tests/echo_srv.c
@@ -5,6 +5,7 @@
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/stat.h>
+#include <sys/wait.h>
#include <arpa/inet.h>
#include <netinet/in.h>
@@ -535,6 +536,7 @@ static void echo_tcp(int sock)
close(s);
exit(0);
}
+ waitpid(-1, NULL, 0);
close(s);
}