mirror of
https://github.com/PowerShell/openssh-portable.git
synced 2025-07-27 15:54:22 +02:00
some systems lack SO_REUSEPORT
This commit is contained in:
parent
83b9678a62
commit
c332110291
@ -719,11 +719,11 @@ local_listen(char *host, char *port, struct addrinfo hints)
|
|||||||
&rtableid, sizeof(rtableid)) == -1))
|
&rtableid, sizeof(rtableid)) == -1))
|
||||||
err(1, "setsockopt SO_RTABLE");
|
err(1, "setsockopt SO_RTABLE");
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef SO_REUSEPORT
|
||||||
ret = setsockopt(s, SOL_SOCKET, SO_REUSEPORT, &x, sizeof(x));
|
ret = setsockopt(s, SOL_SOCKET, SO_REUSEPORT, &x, sizeof(x));
|
||||||
if (ret == -1)
|
if (ret == -1)
|
||||||
err(1, NULL);
|
err(1, NULL);
|
||||||
|
#endif
|
||||||
set_common_sockopts(s);
|
set_common_sockopts(s);
|
||||||
|
|
||||||
if (bind(s, (struct sockaddr *)res0->ai_addr,
|
if (bind(s, (struct sockaddr *)res0->ai_addr,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user