mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-21 02:10:05 +00:00
d369ad760d
2006-02-12 Ulrich Drepper <drepper@redhat.com> * io/ftw.c: Start using *at functions. * io/ftw64.c: Likewise. * sysdeps/generic/not-cancel.h: Define openat_not_cancel, openat_not_cancel_3, openat64_not_cancel, and openat64_not_cancel_3. * sysdeps/unix/sysv/linux/not-cancel.h: Likewise. * sysdeps/unix/sysv/linux/openat.c: Create separate _nocancel functions. * io/fxstatat.c: Add __fxstatat alias. * sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c: Likewise. * sysdeps/unix/sysv/linux/fxstatat.c: Likewise. Add support for newfstatat syscall. * sysdeps/unix/sysv/linux/i386/fxstatat.c: Add __fxstatat alias. Add support for fstatat64 syscall. * include/sys/stat.h: Declare __fxstatat. * io/fxstatat64.c: Add __fxstatat64 alias. * sysdeps/unix/sysv/linux/fxstatat64.c: Add support for fstatat64 syscall. * dirent/fdopendir.c: Add __fdopendir alias. * sysdeps/unix/fdopendir.c: Likewise. * sysdeps/mach/hurd/fdopendir.c: Likewise. * include/dirent.h: Add __fdopendir declaration. [BZ #2226] * libio/wgenops.c (_IO_wsetb): Use correct size of wide char buffer in FREE_BUF call.
52 lines
2.0 KiB
C
52 lines
2.0 KiB
C
#ifndef _SYS_STAT_H
|
|
#include <io/sys/stat.h>
|
|
|
|
/* Now define the internal interfaces. */
|
|
extern int __stat (__const char *__file, struct stat *__buf);
|
|
extern int __fstat (int __fd, struct stat *__buf);
|
|
extern int __lstat (__const char *__file, struct stat *__buf);
|
|
extern int __chmod (__const char *__file, __mode_t __mode);
|
|
extern int __fchmod (int __fd, __mode_t __mode);
|
|
extern __mode_t __umask (__mode_t __mask);
|
|
extern int __mkdir (__const char *__path, __mode_t __mode);
|
|
extern int __mknod (__const char *__path,
|
|
__mode_t __mode, __dev_t __dev);
|
|
#if !defined NOT_IN_libc || defined IS_IN_rtld
|
|
hidden_proto (__fxstat)
|
|
hidden_proto (__fxstat64)
|
|
hidden_proto (__lxstat)
|
|
hidden_proto (__lxstat64)
|
|
hidden_proto (__xstat)
|
|
hidden_proto (__xstat64)
|
|
#endif
|
|
extern __inline__ int __stat (__const char *__path, struct stat *__statbuf)
|
|
{
|
|
return __xstat (_STAT_VER, __path, __statbuf);
|
|
}
|
|
libc_hidden_proto (__xmknod)
|
|
extern __inline__ int __mknod (__const char *__path, __mode_t __mode,
|
|
__dev_t __dev)
|
|
{
|
|
return __xmknod (_MKNOD_VER, __path, __mode, &__dev);
|
|
}
|
|
libc_hidden_proto (__xmknodat)
|
|
|
|
libc_hidden_proto (__fxstatat)
|
|
libc_hidden_proto (__fxstatat64)
|
|
|
|
|
|
/* The `stat', `fstat', `lstat' functions have to be handled special since
|
|
even while not compiling the library with optimization calls to these
|
|
functions in the shared library must reference the `xstat' etc functions.
|
|
We have to use macros but we cannot define them in the normal headers
|
|
since on user level we must use real functions. */
|
|
#define stat(fname, buf) __xstat (_STAT_VER, fname, buf)
|
|
#define lstat(fname, buf) __lxstat (_STAT_VER, fname, buf)
|
|
#define __lstat(fname, buf) __lxstat (_STAT_VER, fname, buf)
|
|
#define lstat64(fname, buf) __lxstat64 (_STAT_VER, fname, buf)
|
|
#define stat64(fname, buf) __xstat64 (_STAT_VER, fname, buf)
|
|
#define fstat64(fd, buf) __fxstat64 (_STAT_VER, fd, buf)
|
|
#define fstat(fd, buf) __fxstat (_STAT_VER, fd, buf)
|
|
#define __fstat(fd, buf) __fxstat (_STAT_VER, fd, buf)
|
|
#endif
|