Disable keepalives on old clang compiler used for nightly
until we can upgrade it
This commit is contained in:
parent
1d8f80c8f7
commit
19f2869490
1 changed files with 6 additions and 3 deletions
|
|
@ -85,19 +85,22 @@ namespace fc {
|
|||
NULL, 0, &dwBytesRet, NULL, NULL) == SOCKET_ERROR)
|
||||
wlog("Error setting TCP keepalive values");
|
||||
#else
|
||||
# if !defined(__clang__) || (__clang_major__ >= 6)
|
||||
a b a c d asdflkjasdfjklasldjf lkjasdjfklja ksdfj k
|
||||
// This should work for modern Linuxes and for OSX >= Mountain Lion
|
||||
int timeout_sec = interval.count() / fc::seconds(1).count();
|
||||
if (setsockopt(my->_sock.native(), IPPROTO_TCP,
|
||||
# if defined( __APPLE__ )
|
||||
# if defined( __APPLE__ )
|
||||
TCP_KEEPALIVE,
|
||||
# else
|
||||
# else
|
||||
TCP_KEEPIDLE,
|
||||
# endif
|
||||
# endif
|
||||
(char*)&timeout_sec, sizeof(timeout_sec)) < 0)
|
||||
wlog("Error setting TCP keepalive idle time");
|
||||
if (setsockopt(my->_sock.native(), IPPROTO_TCP, TCP_KEEPINTVL,
|
||||
(char*)&timeout_sec, sizeof(timeout_sec)) < 0)
|
||||
wlog("Error setting TCP keepalive interval");
|
||||
# endif
|
||||
#endif
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in a new issue