diff options
author | Dan Fandrich <dan@coneharvesters.com> | 2008-11-28 22:07:40 +0000 |
---|---|---|
committer | Dan Fandrich <dan@coneharvesters.com> | 2008-11-28 22:07:40 +0000 |
commit | 36a6a6e175d977856e16dd0d8b645ef9906bafe5 (patch) | |
tree | 7fc3cfcb58e6e71b48a82bcb93d6a942989b1ac8 /ares_process.c | |
parent | 3b6b1979bf176d2eb299f25173207ed4f20d6795 (diff) | |
download | c-ares-36a6a6e175d977856e16dd0d8b645ef9906bafe5.tar.gz c-ares-36a6a6e175d977856e16dd0d8b645ef9906bafe5.tar.bz2 c-ares-36a6a6e175d977856e16dd0d8b645ef9906bafe5.zip |
Only set TCP_NODELAY when it exists
Diffstat (limited to 'ares_process.c')
-rw-r--r-- | ares_process.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ares_process.c b/ares_process.c index 05341aa..58f0725 100644 --- a/ares_process.c +++ b/ares_process.c @@ -897,6 +897,7 @@ static int open_tcp_socket(ares_channel channel, struct server_state *server) return -1; } +#ifdef TCP_NODELAY /* * Disable the Nagle algorithm (only relevant for TCP sockets, and thus not in * configure_socket). In general, in DNS lookups we're pretty much interested @@ -910,6 +911,7 @@ static int open_tcp_socket(ares_channel channel, struct server_state *server) closesocket(s); return -1; } +#endif /* Connect to the server. */ memset(&sockin, 0, sizeof(sockin)); |