mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-26 23:10:06 +00:00
Update.
* sysdeps/unix/sysv/linux/gethostid.c: Find hostid file in /etc. * sysdeps/mips/dl-machine.h (RESOLVE_GOTSYM): Fix calls to dl_lookup.
This commit is contained in:
parent
377f602036
commit
e0baae1264
@ -1,5 +1,7 @@
|
||||
2000-09-07 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* sysdeps/unix/sysv/linux/gethostid.c: Find hostid file in /etc.
|
||||
|
||||
* scripts/config.sub: Strip out -unknown for Linux targets.
|
||||
Patch by Scott Bambrough <scottb@netwinder.org>.
|
||||
|
||||
@ -15,8 +17,7 @@
|
||||
|
||||
* sysdeps/unix/sysv/linux/mips/syscalls.list: Add __syscall_fcntl.
|
||||
|
||||
* sysdeps/mips/dl-machine.h (RESOLVE_GOTSYM): Fix calls to
|
||||
dl_lookup.
|
||||
* sysdeps/mips/dl-machine.h (RESOLVE_GOTSYM): Fix calls to dl_lookup.
|
||||
(ELF_MACHINE_RUNTIME_TRAMPOLINE): Likewise.
|
||||
|
||||
* sysdeps/unix/sysv/linux/mips/fcntl.c: New file.
|
||||
|
@ -21,7 +21,8 @@
|
||||
#include <unistd.h>
|
||||
#include <netdb.h>
|
||||
|
||||
#define HOSTIDFILE "/var/adm/hostid"
|
||||
#define HOSTIDFILE "/etc/hostid"
|
||||
#define OLD_HOSTIDFILE "/etc/hostid"
|
||||
|
||||
#ifdef SET_PROCEDURE
|
||||
int
|
||||
@ -70,6 +71,8 @@ gethostid ()
|
||||
|
||||
/* First try to get the ID from a former invocation of sethostid. */
|
||||
fd = __open (HOSTIDFILE, O_RDONLY);
|
||||
if (fd < 0)
|
||||
fd = __open (OLD_HOSTIDFILE, O_RDONLY);
|
||||
if (fd >= 0)
|
||||
{
|
||||
ssize_t n = __read (fd, &id, sizeof (id));
|
||||
|
Loading…
Reference in New Issue
Block a user