You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zookeeper.apache.org by ph...@apache.org on 2010/07/05 22:32:03 UTC
svn commit: r960686 - in /hadoop/zookeeper/trunk: CHANGES.txt
src/c/src/zookeeper.c
Author: phunt
Date: Mon Jul 5 20:32:03 2010
New Revision: 960686
URL: http://svn.apache.org/viewvc?rev=960686&view=rev
Log:
ZOOKEEPER-797 c client source with AI_ADDRCONFIG cannot be compiled with early glibc
Modified:
hadoop/zookeeper/trunk/CHANGES.txt
hadoop/zookeeper/trunk/src/c/src/zookeeper.c
Modified: hadoop/zookeeper/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/zookeeper/trunk/CHANGES.txt?rev=960686&r1=960685&r2=960686&view=diff
==============================================================================
--- hadoop/zookeeper/trunk/CHANGES.txt (original)
+++ hadoop/zookeeper/trunk/CHANGES.txt Mon Jul 5 20:32:03 2010
@@ -78,6 +78,9 @@ IMPROVEMENTS:
ZOOKEEPER-798. Fixup loggraph for FLE changes (Ivan Kelly via phunt)
+ ZOOKEEPER-797 c client source with AI_ADDRCONFIG cannot be compiled with
+ early glibc (Qian Ye via phunt)
+
NEW FEATURES:
ZOOKEEPER-729. Java client API to recursively delete a subtree.
(Kay Kay via henry)
Modified: hadoop/zookeeper/trunk/src/c/src/zookeeper.c
URL: http://svn.apache.org/viewvc/hadoop/zookeeper/trunk/src/c/src/zookeeper.c?rev=960686&r1=960685&r2=960686&view=diff
==============================================================================
--- hadoop/zookeeper/trunk/src/c/src/zookeeper.c (original)
+++ hadoop/zookeeper/trunk/src/c/src/zookeeper.c Mon Jul 5 20:32:03 2010
@@ -545,6 +545,7 @@ int getaddrs(zhandle_t *zh)
//bug in getaddrinfo implementation when it returns
//EAI_BADFLAGS or EAI_ADDRFAMILY with AF_UNSPEC and
// ai_flags as AI_ADDRCONFIG
+#ifdef AI_ADDRCONFIG
if ((hints.ai_flags == AI_ADDRCONFIG) &&
((rc ==EAI_BADFLAGS) || (rc == EAI_ADDRFAMILY))) {
//reset ai_flags to null
@@ -552,6 +553,7 @@ int getaddrs(zhandle_t *zh)
//retry getaddrinfo
rc = getaddrinfo(host, port_spec, &hints, &res0);
}
+#endif
if (rc != 0) {
errno = getaddrinfo_errno(rc);
LOG_ERROR(("getaddrinfo: %s\n", strerror(errno)));