Update.
* resolv/nss_dns/dns-host.c: Avoid using PLTs.
This commit is contained in:
parent
b31b32b3aa
commit
78d8d2117b
@ -1,5 +1,6 @@
|
||||
2004-10-24 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* resolv/nss_dns/dns-host.c: Avoid using PLTs.
|
||||
* include/libc-symbols.h: Define hidden attribute macros for
|
||||
libnss_nisplus and libutil.
|
||||
* include/utmp.h: Add libutil_hidden_proto for login_tty.
|
||||
@ -10,7 +11,6 @@
|
||||
* include/rpcsvc/yp.h: New file.
|
||||
* include/rpcsvc/ypclnt.h: New file.
|
||||
* include/rpcsvc/ypupd.h: New file.
|
||||
|
||||
* include/libc-symbols.h: Define hidden attribute macros for libnsl.
|
||||
* include/rpcsvc/nislib.h: Use libnsl_hidden_proto for various
|
||||
functions.
|
||||
|
@ -1,3 +1,8 @@
|
||||
2004-10-24 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* sysdeps/unix/sysv/linux/smp.h (is_smp_system): Use
|
||||
not-cancelable I/O functions.
|
||||
|
||||
2004-10-21 Kaz Kojima <kkojima@rr.iij4u.or.jp>
|
||||
|
||||
* sysdeps/unix/sysv/linux/sh/lowlevellock.S
|
||||
|
@ -20,6 +20,7 @@
|
||||
#include <fcntl.h>
|
||||
#include <string.h>
|
||||
#include <sys/sysctl.h>
|
||||
#include <not-cancel.h>
|
||||
|
||||
/* Test whether the machine has more than one processor. This is not the
|
||||
best test but good enough. More complicated tests would require `malloc'
|
||||
@ -37,13 +38,13 @@ is_smp_system (void)
|
||||
buf, &reslen, NULL, 0) < 0)
|
||||
{
|
||||
/* This was not successful. Now try reading the /proc filesystem. */
|
||||
int fd = __open ("/proc/sys/kernel/version", O_RDONLY);
|
||||
int fd = open_not_cancel_2 ("/proc/sys/kernel/version", O_RDONLY);
|
||||
if (__builtin_expect (fd, 0) == -1
|
||||
|| (reslen = __read (fd, buf, sizeof (buf))) <= 0)
|
||||
|| (reslen = read_not_cancel (fd, buf, sizeof (buf))) <= 0)
|
||||
/* This also didn't work. We give up and say it's a UP machine. */
|
||||
buf[0] = '\0';
|
||||
|
||||
__close (fd);
|
||||
close_not_cancel_no_status (fd);
|
||||
}
|
||||
|
||||
return strstr (buf, "SMP") != NULL;
|
||||
|
@ -127,6 +127,14 @@ static enum nss_status getanswer_r (const querybuf *answer, int anslen,
|
||||
size_t buflen, int *errnop, int *h_errnop,
|
||||
int map, int32_t *ttlp, char **canonp);
|
||||
|
||||
extern enum nss_status _nss_dns_gethostbyname3_r (const char *name, int af,
|
||||
struct hostent *result,
|
||||
char *buffer, size_t buflen,
|
||||
int *errnop, int *h_errnop,
|
||||
int32_t *ttlp,
|
||||
char **canonp);
|
||||
hidden_proto (_nss_dns_gethostbyname3_r)
|
||||
|
||||
enum nss_status
|
||||
_nss_dns_gethostbyname3_r (const char *name, int af, struct hostent *result,
|
||||
char *buffer, size_t buflen, int *errnop,
|
||||
@ -216,6 +224,7 @@ _nss_dns_gethostbyname3_r (const char *name, int af, struct hostent *result,
|
||||
free (host_buffer.buf);
|
||||
return status;
|
||||
}
|
||||
hidden_def (_nss_dns_gethostbyname3_r)
|
||||
|
||||
|
||||
enum nss_status
|
||||
@ -236,11 +245,11 @@ _nss_dns_gethostbyname_r (const char *name, struct hostent *result,
|
||||
enum nss_status status = NSS_STATUS_NOTFOUND;
|
||||
|
||||
if (_res.options & RES_USE_INET6)
|
||||
status = _nss_dns_gethostbyname2_r (name, AF_INET6, result, buffer,
|
||||
buflen, errnop, h_errnop);
|
||||
status = _nss_dns_gethostbyname3_r (name, AF_INET6, result, buffer,
|
||||
buflen, errnop, h_errnop, NULL, NULL);
|
||||
if (status == NSS_STATUS_NOTFOUND)
|
||||
status = _nss_dns_gethostbyname2_r (name, AF_INET, result, buffer,
|
||||
buflen, errnop, h_errnop);
|
||||
status = _nss_dns_gethostbyname3_r (name, AF_INET, result, buffer,
|
||||
buflen, errnop, h_errnop, NULL, NULL);
|
||||
|
||||
return status;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user