summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2011-04-21 21:45:46 +0200
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2012-06-15 14:00:40 +0200
commit9df9c60aa93287211cf9698eb979d80fded765dc (patch)
tree0564ac7a49e3ebe1aacb47db6b13cefe86bc80dd /include
parentf6a03f19cf2807170717593b4de8056a1248b99b (diff)
add cancellation for read, write, close
close.c: add function __close_nocancel_no_status to be used internally in libc avoiding inlining it everywhere. Signed-off-by: Peter S. Mazinger <ps.m@gmx.net> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Diffstat (limited to 'include')
-rw-r--r--include/unistd.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/unistd.h b/include/unistd.h
index a886ad1a8..2d53aa4b9 100644
--- a/include/unistd.h
+++ b/include/unistd.h
@@ -354,7 +354,11 @@ libc_hidden_proto(lseek64)
This function is a cancellation point and therefore not marked with
__THROW. */
extern int close (int __fd);
+#ifdef _LIBC
+extern __typeof(close) __close_nocancel attribute_hidden;
+extern void __close_nocancel_no_status(int) attribute_hidden;
libc_hidden_proto(close)
+#endif
/* Read NBYTES into BUF from FD. Return the
number read, -1 for errors or 0 for EOF.
@@ -362,14 +366,20 @@ libc_hidden_proto(close)
This function is a cancellation point and therefore not marked with
__THROW. */
extern ssize_t read (int __fd, void *__buf, size_t __nbytes) __wur;
+#ifdef _LIBC
+extern __typeof(read) __read_nocancel attribute_hidden;
libc_hidden_proto(read)
+#endif
/* Write N bytes of BUF to FD. Return the number written, or -1.
This function is a cancellation point and therefore not marked with
__THROW. */
extern ssize_t write (int __fd, __const void *__buf, size_t __n) __wur;
+#ifdef _LIBC
+extern __typeof(write) __write_nocancel attribute_hidden;
libc_hidden_proto(write)
+#endif
#ifdef __USE_UNIX98
# ifndef __USE_FILE_OFFSET64