diff options
Diffstat (limited to 'netwerk/base/nsSocketTransport2.cpp')
-rw-r--r-- | netwerk/base/nsSocketTransport2.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/netwerk/base/nsSocketTransport2.cpp b/netwerk/base/nsSocketTransport2.cpp index 0c8434813..76a357aa3 100644 --- a/netwerk/base/nsSocketTransport2.cpp +++ b/netwerk/base/nsSocketTransport2.cpp @@ -3048,9 +3048,8 @@ nsSocketTransport::PRFileDescAutoLock::SetKeepaliveVals(bool aEnabled, #elif defined(XP_UNIX) // Not all *nix OSes support the following setsockopt() options - // ... but we assume they are supported in the Android kernel; // build errors will tell us if they are not. -#if defined(ANDROID) || defined(TCP_KEEPIDLE) +#ifdef TCP_KEEPIDLE // Idle time until first keepalive probe; interval between ack'd probes; seconds. int err = setsockopt(sock, IPPROTO_TCP, TCP_KEEPIDLE, &aIdleTime, sizeof(aIdleTime)); @@ -3061,7 +3060,7 @@ nsSocketTransport::PRFileDescAutoLock::SetKeepaliveVals(bool aEnabled, } #endif -#if defined(ANDROID) || defined(TCP_KEEPINTVL) +#ifdef TCP_KEEPINTVL // Interval between unack'd keepalive probes; seconds. err = setsockopt(sock, IPPROTO_TCP, TCP_KEEPINTVL, &aRetryInterval, sizeof(aRetryInterval)); @@ -3072,7 +3071,7 @@ nsSocketTransport::PRFileDescAutoLock::SetKeepaliveVals(bool aEnabled, } #endif -#if defined(ANDROID) || defined(TCP_KEEPCNT) +#ifdef TCP_KEEPCNT // Number of unack'd keepalive probes before connection times out. err = setsockopt(sock, IPPROTO_TCP, TCP_KEEPCNT, &aProbeCount, sizeof(aProbeCount)); |