diff options
| author | Anton <anton@picapica> | 2019-03-10 22:05:48 +0400 |
|---|---|---|
| committer | Anton <anton@picapica> | 2019-03-10 22:05:48 +0400 |
| commit | 0a6c2d173dfdfc8260e05e072a560821ba401f10 (patch) | |
| tree | df1e01c3c33c9b0a6386ea01e4ba702c2c17ac11 /PICA_node.c | |
| parent | 3be26cf2842fe7526b847b05dc99c31dc15fb97d (diff) | |
| download | pica-pica-0a6c2d173dfdfc8260e05e072a560821ba401f10.tar.gz pica-pica-0a6c2d173dfdfc8260e05e072a560821ba401f10.zip | |
pica-node: do not set socket option SO_REUSEADDR on windows
Diffstat (limited to 'PICA_node.c')
| -rw-r--r-- | PICA_node.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/PICA_node.c b/PICA_node.c index eafc398..2c4b029 100644 --- a/PICA_node.c +++ b/PICA_node.c @@ -1597,13 +1597,13 @@ int PICA_node_init() if (listen_comm_sck == -1) PICA_fatal("unable to get socket - %s", strerror(errno)); - +#ifndef WIN32 flag = 1; //enable SO_REUSEADDR if (0 != setsockopt(listen_comm_sck, SOL_SOCKET, SO_REUSEADDR, &flag, sizeof(flag))) { PICA_error("failed to set SO_REUSEADDR on socket: %s", strerror(errno)); } - +#endif memset(&sd, 0, sizeof(sd)); sd.sin_family = AF_INET; |
