diff options
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/i386')
-rw-r--r-- | nptl/sysdeps/unix/sysv/linux/i386/not-cancel.h | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/i386/not-cancel.h b/nptl/sysdeps/unix/sysv/linux/i386/not-cancel.h index 77ea727969..693cd07b14 100644 --- a/nptl/sysdeps/unix/sysv/linux/i386/not-cancel.h +++ b/nptl/sysdeps/unix/sysv/linux/i386/not-cancel.h @@ -1,4 +1,4 @@ -/* Uncancelable versions of cancelable interfaces. Linux version. +/* Uncancelable versions of cancelable interfaces. Linux/NPTL version. Copyright (C) 2003 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper <drepper@redhat.com>, 2003. @@ -20,15 +20,28 @@ #include <sysdep.h> +#if !defined NOT_IN_libc || defined IS_IN_libpthread || defined IS_IN_librt +extern int __open_nocancel (const char *, int, ...) attribute_hidden; +extern int __close_nocancel (int) attribute_hidden; +extern int __read_nocancel (int, void *, size_t) attribute_hidden; +extern int __write_nocancel (int, const void *, size_t) attribute_hidden; +extern pid_t __waitpid_nocancel (pid_t, int *, int) attribute_hidden; +#else +#define __open_nocancel(name, ...) __open (name, __VA_ARGS__) +#define __close_nocancel(fd) __close (fd) +#define __read_nocancel(fd, buf, len) __read (fd, buf, len) +#define __write_nocancel(fd, buf, len) __write (fd, buf, len) +#define __waitpid_nocancel(pid, stat_loc, options) \ + __waitpid (pid, stat_loc, options) +#endif + /* Uncancelable open. */ -extern int __open_nocancel (const char *, int, ...); #define open_not_cancel(name, flags, mode) \ __open_nocancel (name, flags, mode) #define open_not_cancel_2(name, flags) \ __open_nocancel (name, flags) /* Uncancelable close. */ -extern int __close_nocancel (int); #define close_not_cancel(fd) \ __close_nocancel (fd) #define close_not_cancel_no_status(fd) \ @@ -36,12 +49,10 @@ extern int __close_nocancel (int); INTERNAL_SYSCALL (close, err, 1, (fd)); }) /* Uncancelable read. */ -extern int __read_nocancel (int, void *, size_t); #define read_not_cancel(fd, buf, n) \ __read_nocancel (fd, buf, n) /* Uncancelable write. */ -extern int __write_nocancel (int, const void *, size_t); #define write_not_cancel(fd, buf, n) \ __write_nocancel (fd, buf, n) @@ -52,7 +63,6 @@ extern int __write_nocancel (int, const void *, size_t); /* Uncancelable waitpid. */ #ifdef __NR_waitpid -extern pid_t __waitpid_nocancel (pid_t, int *, int); # define waitpid_not_cancel(pid, stat_loc, options) \ __waitpid_nocancel (pid, stat_loc, options) #else |