This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch master updated. glibc-2.18-475-g639a0ef
- From: siddhesh at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 2 Dec 2013 14:55:58 -0000
- Subject: GNU C Library master sources branch master updated. glibc-2.18-475-g639a0ef
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, master has been updated
via 639a0ef8aba38b3ba1628d539fa95078132bca8a (commit)
via f524d6a8e41a6baae75bc3b400374fb3367c111a (commit)
via df3aedaf38df715f5faf3a0a2795e61098980963 (commit)
via b42ad38d63776fc973b234fa17c429b4a06c6fa6 (commit)
from 2a939a7e6d81f109d49306bc2e10b4ac9ceed8f9 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=639a0ef8aba38b3ba1628d539fa95078132bca8a
commit 639a0ef8aba38b3ba1628d539fa95078132bca8a
Author: Pavel Simerda <psimerda@redhat.com>
Date: Mon Dec 2 20:23:13 2013 +0530
Remove redundant GAIH_OKIFUNSPEC and GAIH_EAI.
Only gaih_inet() and gaih_inet_serv() use a special bit flag denoted
by the GAIH_OKIFUNSPEC macro. Only the return value of
gaih_inet_serv() is actively checked for the bit flag which is
redundant because it just copies the nonzero property of the value
otherwise returned. The return value of gaih_inet() is only checked
for being zero and then the bit flag is filtered out. As the bit flag
is set only for otherwise nonzero return values, it doesn't affect the
zero comparison. GAIH_EAI just an alias to ~GAIH_OKIFUNSPEC.
diff --git a/ChangeLog b/ChangeLog
index 1515942..8e6b527 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2013-12-02 Pavel Simerda <psimerda@redhat.com>
+ * sysdeps/posix/getaddrinfo.c (GAIH_OKIFUNSPEC): Remove macro.
+ (GAIH_EAI): Likewise.
+ (gaih_inet_serv): Don't use GAIH_OKIFUNSPEC.
+ (gaih_inet): Likewise.
+ (getaddrinfo): Don't use GAIH_EAI.
+
* sysdeps/posix/getaddrinfo.c (UNIX_PATH_MAX): Remove macro.
(struct gaih): Remove definition.
diff --git a/sysdeps/posix/getaddrinfo.c b/sysdeps/posix/getaddrinfo.c
index 387c22f..8218237 100644
--- a/sysdeps/posix/getaddrinfo.c
+++ b/sysdeps/posix/getaddrinfo.c
@@ -71,9 +71,6 @@ extern int __idna_to_unicode_lzlz (const char *input, char **output,
# include <libidn/idna.h>
#endif
-#define GAIH_OKIFUNSPEC 0x0100
-#define GAIH_EAI ~(GAIH_OKIFUNSPEC)
-
struct gaih_service
{
const char *name;
@@ -157,7 +154,7 @@ gaih_inet_serv (const char *servicename, const struct gaih_typeproto *tp,
if (r == ERANGE)
tmpbuflen *= 2;
else
- return GAIH_OKIFUNSPEC | -EAI_SERVICE;
+ return -EAI_SERVICE;
}
}
while (r);
@@ -299,9 +296,9 @@ gaih_inet (const char *name, const struct gaih_service *service,
if (! tp->name[0])
{
if (req->ai_socktype)
- return GAIH_OKIFUNSPEC | -EAI_SOCKTYPE;
+ return -EAI_SOCKTYPE;
else
- return GAIH_OKIFUNSPEC | -EAI_SERVICE;
+ return -EAI_SERVICE;
}
}
@@ -309,7 +306,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
if (service != NULL)
{
if ((tp->protoflag & GAI_PROTO_NOSERVICE) != 0)
- return GAIH_OKIFUNSPEC | -EAI_SERVICE;
+ return -EAI_SERVICE;
if (service->num < 0)
{
@@ -345,7 +342,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
if ((rc = gaih_inet_serv (service->name, tp, req, newp)))
{
- if (rc & GAIH_OKIFUNSPEC)
+ if (rc)
continue;
return rc;
}
@@ -354,7 +351,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
pst = &(newp->next);
}
if (st == (struct gaih_servtuple *) &nullserv)
- return GAIH_OKIFUNSPEC | -EAI_SERVICE;
+ return -EAI_SERVICE;
}
}
else
@@ -546,7 +543,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
10);
if (*end != '\0')
{
- result = GAIH_OKIFUNSPEC | -EAI_NONAME;
+ result = -EAI_NONAME;
goto free_and_return;
}
}
@@ -667,7 +664,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
else
/* We made requests but they turned out no data.
The name is known, though. */
- result = GAIH_OKIFUNSPEC | -EAI_NODATA;
+ result = -EAI_NODATA;
goto free_and_return;
}
@@ -773,7 +770,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
if (at->family == AF_UNSPEC)
{
- result = GAIH_OKIFUNSPEC | -EAI_NONAME;
+ result = -EAI_NONAME;
goto free_and_return;
}
@@ -1064,7 +1061,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
if (h_errno == NETDB_INTERNAL)
{
- result = GAIH_OKIFUNSPEC | -EAI_SYSTEM;
+ result = -EAI_SYSTEM;
goto free_and_return;
}
@@ -1076,7 +1073,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
else
/* We made requests but they turned out no data. The name
is known, though. */
- result = GAIH_OKIFUNSPEC | -EAI_NODATA;
+ result = -EAI_NODATA;
goto free_and_return;
}
@@ -1085,7 +1082,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
process_list:
if (at->family == AF_UNSPEC)
{
- result = GAIH_OKIFUNSPEC | -EAI_NONAME;
+ result = -EAI_NONAME;
goto free_and_return;
}
}
@@ -2412,7 +2409,7 @@ getaddrinfo (const char *name, const char *service,
freeaddrinfo (p);
__free_in6ai (in6ai);
- return -(last_i & GAIH_EAI);
+ return -last_i;
}
while (*end)
{
@@ -2645,7 +2642,7 @@ getaddrinfo (const char *name, const char *service,
return 0;
}
- return last_i ? -(last_i & GAIH_EAI) : EAI_NONAME;
+ return last_i ? -last_i : EAI_NONAME;
}
libc_hidden_def (getaddrinfo)
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=f524d6a8e41a6baae75bc3b400374fb3367c111a
commit f524d6a8e41a6baae75bc3b400374fb3367c111a
Author: Pavel Simerda <psimerda@redhat.com>
Date: Mon Dec 2 20:17:17 2013 +0530
getaddrinfo: remove dead code
diff --git a/ChangeLog b/ChangeLog
index 7afaeca..1515942 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2013-12-02 Pavel Simerda <psimerda@redhat.com>
+
+ * sysdeps/posix/getaddrinfo.c (UNIX_PATH_MAX): Remove macro.
+ (struct gaih): Remove definition.
+
2013-12-02 Siddhesh Poyarekar <siddhesh@redhat.com>
* nss/nss_files/files-hosts.c (_nss_files_gethostbyname4_r):
diff --git a/sysdeps/posix/getaddrinfo.c b/sysdeps/posix/getaddrinfo.c
index 8ff74b4..387c22f 100644
--- a/sysdeps/posix/getaddrinfo.c
+++ b/sysdeps/posix/getaddrinfo.c
@@ -74,10 +74,6 @@ extern int __idna_to_unicode_lzlz (const char *input, char **output,
#define GAIH_OKIFUNSPEC 0x0100
#define GAIH_EAI ~(GAIH_OKIFUNSPEC)
-#ifndef UNIX_PATH_MAX
-# define UNIX_PATH_MAX 108
-#endif
-
struct gaih_service
{
const char *name;
@@ -127,14 +123,6 @@ static const struct gaih_typeproto gaih_inet_typeproto[] =
{ 0, 0, 0, false, "" }
};
-struct gaih
- {
- int family;
- int (*gaih)(const char *name, const struct gaih_service *service,
- const struct addrinfo *req, struct addrinfo **pai,
- unsigned int *naddrs);
- };
-
static const struct addrinfo default_hints =
{
.ai_flags = AI_DEFAULT,
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=df3aedaf38df715f5faf3a0a2795e61098980963
commit df3aedaf38df715f5faf3a0a2795e61098980963
Author: Siddhesh Poyarekar <siddhesh@redhat.com>
Date: Mon Dec 2 20:06:20 2013 +0530
Use herrnop directly
H_ERRNO_ARGS is unnecessary since we this file is specifically for
hosts lookup.
diff --git a/ChangeLog b/ChangeLog
index ad1bdf6..7afaeca 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2013-12-02 Siddhesh Poyarekar <siddhesh@redhat.com>
+
+ * nss/nss_files/files-hosts.c (_nss_files_gethostbyname4_r):
+ Use HERRNOP directly.
+
2013-12-02 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
* sysdeps/powerpc/fpu/libm-test-ulps: Update.
diff --git a/nss/nss_files/files-hosts.c b/nss/nss_files/files-hosts.c
index 957c9aa..cfec75d 100644
--- a/nss/nss_files/files-hosts.c
+++ b/nss/nss_files/files-hosts.c
@@ -399,8 +399,8 @@ _nss_files_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
buflen = buflen > pad ? buflen - pad : 0;
struct hostent result;
- status = internal_getent (&result, buffer, buflen, errnop
- H_ERRNO_ARG, AF_UNSPEC, 0);
+ status = internal_getent (&result, buffer, buflen, errnop,
+ herrnop, AF_UNSPEC, 0);
if (status != NSS_STATUS_SUCCESS)
break;
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=b42ad38d63776fc973b234fa17c429b4a06c6fa6
commit b42ad38d63776fc973b234fa17c429b4a06c6fa6
Author: Siddhesh Poyarekar <siddhesh@redhat.com>
Date: Mon Dec 2 20:05:30 2013 +0530
Fix ChangeLog formatting
diff --git a/ChangeLog b/ChangeLog
index 2b91fc9..ad1bdf6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,6 @@
2013-12-02 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
- * sysdeps/powerpc/fpu/libm-test-ulps: Update.
+ * sysdeps/powerpc/fpu/libm-test-ulps: Update.
2013-11-30 Joseph Myers <joseph@codesourcery.com>
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 18 +++++++++++++++++-
nss/nss_files/files-hosts.c | 4 ++--
sysdeps/posix/getaddrinfo.c | 43 ++++++++++++++-----------------------------
3 files changed, 33 insertions(+), 32 deletions(-)
hooks/post-receive
--
GNU C Library master sources