aboutsummaryrefslogtreecommitdiff
path: root/socket/sys/socket.h
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2003-04-19 16:57:17 +0000
committerUlrich Drepper <drepper@redhat.com>2003-04-19 16:57:17 +0000
commit2c008571c3ad156479307b7e23185ae566b5776a (patch)
treef3bad7f0e95a6d172e6577b7e2d557602e1f446c /socket/sys/socket.h
parent76a67697c890d292d9f32e88cf24f8a3f74e47b9 (diff)
downloadglibc-2c008571c3ad156479307b7e23185ae566b5776a.tar
glibc-2c008571c3ad156479307b7e23185ae566b5776a.tar.gz
glibc-2c008571c3ad156479307b7e23185ae566b5776a.tar.bz2
glibc-2c008571c3ad156479307b7e23185ae566b5776a.zip
Update.
2003-04-19 Ulrich Drepper <drepper@redhat.com> * catgets/nl_types.h: Remove __THROW marker from cancellation points. * dirent/dirent.h: Likewise. * dlfcn/dlfcn.h: Likewise. * grp/grp.h: Likewise. * iconv/iconv.h: Likewise. * io/fcntl.h: Likewise. * io/ftw.h: Likewise. * libio/stdio.h: Likewise. * misc/sys/mman.h: Likewise. * misc/sys/select.h: Likewise. * misc/sys/syslog.h: Likewise. * misc/sys/uio.h: Likewise. * posix/spawn.h: Likewise. * posix/unistd.h: Likewise. * posix/sys/wait.h: Likewise. * pwd/pwd.h: Likewise. * resolv/netdb.h: Likewise. * rt/aio.h: Likewise. * shadow/shadow.h: Likewise. * signal/signal.h: Likewise. * socket/sys/socket.h: Likewise. * stdlib/stdlib.h: Likewise. * streams/stropts.h: Likewise. * string/string.h: Likewise. * sysdeps/gnu/utmpx.h: Likewise. * sysvipc/sys/msg.h: Likewise. * termios/termios.h: Likewise. * time/time.h: Likewise. * wcsmbs/wchar.h: Likewise. * iconv/gconv_cache.c: Include <not-cancel.h> and use non-cancelable functions. * misc/daemon.c: Likewise. * sysdeps/generic/backtracesymsfd.c: Likewise. * sysdeps/generic/check_fds.c: Likewise. * sysdeps/unix/sysv/linux/gethostid.c: Likewise. * sysdeps/unix/sysv/linux/not-cancel.h: New file. * sysdeps/generic/not-cancel.h: New file. * csu/Makefile (distribute): Add not-cancel.h. * sysdeps/unix/sysv/linux/fatal-prepare.h: New file. * sysdeps/unix/sysv/linux/Makefile: Define FATAL_PREPARE_INCLUDE for assert.c and assert-perr.c to include <fatal-prepare.h>. * sysdeps/unix/sysv/linux/Dist: Add fatal-prepare.h. * sysdeps/posix/remove.c (remove): Rewrite. No need to restore errno and unlink first. * io/ftw.c (ftw_dir): In all places assume fchdir is available. 2003-04-18 Ulrich Drepper <drepper@redhat.com> * sysdeps/unix/sysv/linux/libc_fatal.c (__libc_fatal): Use INTERNAL_SYSCALL instead of INLINE_SYSCALL.
Diffstat (limited to 'socket/sys/socket.h')
-rw-r--r--socket/sys/socket.h69
1 files changed, 44 insertions, 25 deletions
diff --git a/socket/sys/socket.h b/socket/sys/socket.h
index b57b633499..4ae1ea9808 100644
--- a/socket/sys/socket.h
+++ b/socket/sys/socket.h
@@ -1,5 +1,5 @@
/* Declarations of socket constants, types, and functions.
- Copyright (C) 1991,92,1994-1999,2000,2001 Free Software Foundation, Inc.
+ Copyright (C) 1991,92,1994-2001,2003 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -117,9 +117,11 @@ extern int getsockname (int __fd, __SOCKADDR_ARG __addr,
/* Open a connection on socket FD to peer at ADDR (which LEN bytes long).
For connectionless socket types, just set the default address to send to
and the only address from which to accept transmissions.
- Return 0 on success, -1 for errors. */
-extern int connect (int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len)
- __THROW;
+ Return 0 on success, -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern int connect (int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len);
/* Put the address of the peer connected to socket FD into *ADDR
(which is *LEN bytes long), and its actual length into *LEN. */
@@ -127,39 +129,54 @@ extern int getpeername (int __fd, __SOCKADDR_ARG __addr,
socklen_t *__restrict __len) __THROW;
-/* Send N bytes of BUF to socket FD. Returns the number sent or -1. */
-extern ssize_t send (int __fd, __const void *__buf, size_t __n, int __flags)
- __THROW;
+/* Send N bytes of BUF to socket FD. Returns the number sent or -1.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern ssize_t send (int __fd, __const void *__buf, size_t __n, int __flags);
/* Read N bytes into BUF from socket FD.
- Returns the number read or -1 for errors. */
-extern ssize_t recv (int __fd, void *__buf, size_t __n, int __flags)
- __THROW;
+ Returns the number read or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern ssize_t recv (int __fd, void *__buf, size_t __n, int __flags);
/* Send N bytes of BUF on socket FD to peer at address ADDR (which is
- ADDR_LEN bytes long). Returns the number sent, or -1 for errors. */
+ ADDR_LEN bytes long). Returns the number sent, or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
extern ssize_t sendto (int __fd, __const void *__buf, size_t __n,
int __flags, __CONST_SOCKADDR_ARG __addr,
- socklen_t __addr_len) __THROW;
+ socklen_t __addr_len);
/* Read N bytes into BUF through socket FD.
If ADDR is not NULL, fill in *ADDR_LEN bytes of it with tha address of
the sender, and store the actual size of the address in *ADDR_LEN.
- Returns the number of bytes read or -1 for errors. */
-extern ssize_t recvfrom (int __fd, void *__restrict __buf, size_t __n, int __flags,
- __SOCKADDR_ARG __addr, socklen_t *__restrict __addr_len)
- __THROW;
+ Returns the number of bytes read or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern ssize_t recvfrom (int __fd, void *__restrict __buf, size_t __n,
+ int __flags, __SOCKADDR_ARG __addr,
+ socklen_t *__restrict __addr_len);
/* Send a message described MESSAGE on socket FD.
- Returns the number of bytes sent, or -1 for errors. */
-extern ssize_t sendmsg (int __fd, __const struct msghdr *__message, int __flags)
- __THROW;
+ Returns the number of bytes sent, or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern ssize_t sendmsg (int __fd, __const struct msghdr *__message,
+ int __flags);
/* Receive a message as described by MESSAGE from socket FD.
- Returns the number of bytes read or -1 for errors. */
-extern ssize_t recvmsg (int __fd, struct msghdr *__message, int __flags)
- __THROW;
+ Returns the number of bytes read or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
+extern ssize_t recvmsg (int __fd, struct msghdr *__message, int __flags);
/* Put the current value for socket FD's option OPTNAME at protocol level LEVEL
@@ -185,10 +202,12 @@ extern int listen (int __fd, int __n) __THROW;
When a connection arrives, open a new socket to communicate with it,
set *ADDR (which is *ADDR_LEN bytes long) to the address of the connecting
peer and *ADDR_LEN to the address's actual length, and return the
- new socket's descriptor, or -1 for errors. */
+ new socket's descriptor, or -1 for errors.
+
+ This function is a cancellation point and therefore not marked with
+ __THROW. */
extern int accept (int __fd, __SOCKADDR_ARG __addr,
- socklen_t *__restrict __addr_len)
- __THROW;
+ socklen_t *__restrict __addr_len);
/* Shut down all or part of the connection open on socket FD.
HOW determines what to shut down: