/* tcp trp (transport) - send/receive a bunch of bytes from a tcp socket */
-/* Authors: Martin Quinson */
-/* Copyright (C) 2004 Martin Quinson. */
+/* Copyright (c) 2004 Martin Quinson. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
- under the terms of the license (GNU LGPL) which comes with this package. */
-
-#include <unistd.h> /* close() pipe() read() write() */
-#include <signal.h> /* close() pipe() read() write() */
-#include <netinet/in.h> /* sometimes required for #include <arpa/inet.h> */
-#include <netinet/tcp.h> /* TCP_NODELAY */
-#include <arpa/inet.h> /* inet_ntoa() */
-#include <netdb.h> /* getprotobyname() */
-#include <sys/time.h> /* struct timeval */
-#include <errno.h> /* errno */
-#include <sys/wait.h> /* waitpid() */
-#include <sys/socket.h> /* getpeername() socket() */
-#include <stdlib.h>
-#include <string.h> /* memset */
+ * under the terms of the license (GNU LGPL) which comes with this package. */
+
+#include "portable.h"
+
+#if 0
+# include <unistd.h> /* close() pipe() read() write() */
+# include <signal.h> /* close() pipe() read() write() */
+# include <netinet/in.h> /* sometimes required for #include <arpa/inet.h> */
+# include <netinet/tcp.h> /* TCP_NODELAY */
+# include <arpa/inet.h> /* inet_ntoa() */
+# include <netdb.h> /* getprotobyname() */
+# include <sys/time.h> /* struct timeval */
+# include <errno.h> /* errno */
+# include <sys/wait.h> /* waitpid() */
+# include <sys/socket.h> /* getpeername() socket() */
+# include <stdlib.h>
+# include <string.h> /* memset */
+#endif
+
#include "transport_private.h"
gras_trp_tcp_socket_accept(gras_socket_t sock,
gras_socket_t *dst) {
gras_socket_t res;
- xbt_error_t errcode;
struct sockaddr_in peer_in;
socklen_t peer_in_len = sizeof(peer_in);
int res_last, msg_sofar, exp_sofar;
fd_set rd_set;
- int rv;
+/* int rv; */
struct timeval timeOut;