aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/iomgr/tcp_server_posix.c
diff options
context:
space:
mode:
authorGravatar murgatroid99 <michael.lumish@gmail.com>2015-01-23 09:11:39 -0800
committerGravatar murgatroid99 <michael.lumish@gmail.com>2015-01-23 09:11:39 -0800
commitd10c0abaf646f7635c1c0cb292c44036c6b64c05 (patch)
tree7553a277e129ee2e03782f5c1f6460219cfbc7ab /src/core/iomgr/tcp_server_posix.c
parentb2c86aa8c4a0833fb434e679d2a7dbc93e6fc670 (diff)
parentac139dead15bf9cb8da75340c6fb93225a11ef7c (diff)
Merge branch 'master' of github.com:google/grpc into merge_new_invoke_api
Diffstat (limited to 'src/core/iomgr/tcp_server_posix.c')
-rw-r--r--src/core/iomgr/tcp_server_posix.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/core/iomgr/tcp_server_posix.c b/src/core/iomgr/tcp_server_posix.c
index e6c02186ee..2d6c6a73c2 100644
--- a/src/core/iomgr/tcp_server_posix.c
+++ b/src/core/iomgr/tcp_server_posix.c
@@ -31,6 +31,10 @@
*
*/
+#include <grpc/support/port_platform.h>
+
+#ifdef GPR_POSIX_SOCKET
+
#define _GNU_SOURCE
#include "src/core/iomgr/tcp_server.h"
@@ -265,7 +269,7 @@ static int add_socket_to_server(grpc_tcp_server *s, int fd,
return port;
}
-int grpc_tcp_server_add_port(grpc_tcp_server *s, const struct sockaddr *addr,
+int grpc_tcp_server_add_port(grpc_tcp_server *s, const void *addr,
int addr_len) {
int allocated_port1 = -1;
int allocated_port2 = -1;
@@ -364,3 +368,5 @@ void grpc_tcp_server_start(grpc_tcp_server *s, grpc_pollset *pollset,
}
gpr_mu_unlock(&s->mu);
}
+
+#endif