diff --git a/src/client_new.c b/src/client_new.c index beb8e14b7..781a36524 100644 --- a/src/client_new.c +++ b/src/client_new.c @@ -24,6 +24,12 @@ #include "permission.h" #include +#include +#ifdef WIN32 +#include +#else +#include +#endif #include #ifdef HAVE_LIBWRAP @@ -111,7 +117,7 @@ void client_new(int fd, const struct sockaddr *sa, size_t sa_length, int uid) client->send_buf_used = 0; - (void)write(fd, GREETING, sizeof(GREETING) - 1); + (void)send(fd, GREETING, sizeof(GREETING) - 1, 0); client_list_add(client);