summary refs log tree commit diff
path: root/pwd
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 /pwd
parent76a67697c890d292d9f32e88cf24f8a3f74e47b9 (diff)
downloadglibc-2c008571c3ad156479307b7e23185ae566b5776a.tar.gz
glibc-2c008571c3ad156479307b7e23185ae566b5776a.tar.xz
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 'pwd')
-rw-r--r--pwd/pwd.h83
1 files changed, 61 insertions, 22 deletions
diff --git a/pwd/pwd.h b/pwd/pwd.h
index 8a54578b82..9a9eba43d7 100644
--- a/pwd/pwd.h
+++ b/pwd/pwd.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991,92,95,96,97,98,99,2001 Free Software Foundation, Inc.
+/* Copyright (C) 1991,1992,1995-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
@@ -66,30 +66,55 @@ struct passwd
 
 
 #if defined __USE_SVID || defined __USE_MISC || defined __USE_XOPEN_EXTENDED
-/* Rewind the password-file stream.  */
-extern void setpwent (void) __THROW;
+/* Rewind the password-file stream.
 
-/* Close the password-file stream.  */
-extern void endpwent (void) __THROW;
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern void setpwent (void);
 
-/* Read an entry from the password-file stream, opening it if necessary.  */
-extern struct passwd *getpwent (void) __THROW;
+/* Close the password-file stream.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern void endpwent (void);
+
+/* Read an entry from the password-file stream, opening it if necessary.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern struct passwd *getpwent (void);
 #endif
 
 #ifdef	__USE_SVID
-/* Read an entry from STREAM.  */
-extern struct passwd *fgetpwent (FILE *__stream) __THROW;
+/* Read an entry from STREAM.
+
+   This function is not part of POSIX and therefore no official
+   cancellation point.  But due to similarity with an POSIX interface
+   or due to the implementation it is a cancellation point and
+   therefore not marked with __THROW.  */
+extern struct passwd *fgetpwent (FILE *__stream);
+
+/* Write the given entry onto the given stream.
 
-/* Write the given entry onto the given stream.  */
+   This function is not part of POSIX and therefore no official
+   cancellation point.  But due to similarity with an POSIX interface
+   or due to the implementation it is a cancellation point and
+   therefore not marked with __THROW.  */
 extern int putpwent (__const struct passwd *__restrict __p,
-		     FILE *__restrict __f) __THROW;
+		     FILE *__restrict __f);
 #endif
 
-/* Search for an entry with a matching user ID.  */
-extern struct passwd *getpwuid (__uid_t __uid) __THROW;
+/* Search for an entry with a matching user ID.
 
-/* Search for an entry with a matching username.  */
-extern struct passwd *getpwnam (__const char *__name) __THROW;
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern struct passwd *getpwuid (__uid_t __uid);
+
+/* Search for an entry with a matching username.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern struct passwd *getpwnam (__const char *__name);
 
 #if defined __USE_POSIX || defined __USE_MISC
 
@@ -108,29 +133,38 @@ extern struct passwd *getpwnam (__const char *__name) __THROW;
    POSIX people would choose.  */
 
 # if defined __USE_SVID || defined __USE_MISC
+/* This function is not part of POSIX and therefore no official
+   cancellation point.  But due to similarity with an POSIX interface
+   or due to the implementation it is a cancellation point and
+   therefore not marked with __THROW.  */
 extern int getpwent_r (struct passwd *__restrict __resultbuf,
 		       char *__restrict __buffer, size_t __buflen,
-		       struct passwd **__restrict __result) __THROW;
+		       struct passwd **__restrict __result);
 # endif
 
 extern int getpwuid_r (__uid_t __uid,
 		       struct passwd *__restrict __resultbuf,
 		       char *__restrict __buffer, size_t __buflen,
-		       struct passwd **__restrict __result) __THROW;
+		       struct passwd **__restrict __result);
 
 extern int getpwnam_r (__const char *__restrict __name,
 		       struct passwd *__restrict __resultbuf,
 		       char *__restrict __buffer, size_t __buflen,
-		       struct passwd **__restrict __result) __THROW;
+		       struct passwd **__restrict __result);
 
 
 # ifdef	__USE_SVID
 /* Read an entry from STREAM.  This function is not standardized and
-   probably never will.  */
+   probably never will.
+
+   This function is not part of POSIX and therefore no official
+   cancellation point.  But due to similarity with an POSIX interface
+   or due to the implementation it is a cancellation point and
+   therefore not marked with __THROW.  */
 extern int fgetpwent_r (FILE *__restrict __stream,
 			struct passwd *__restrict __resultbuf,
 			char *__restrict __buffer, size_t __buflen,
-			struct passwd **__restrict __result) __THROW;
+			struct passwd **__restrict __result);
 # endif
 
 #endif	/* POSIX or reentrant */
@@ -138,8 +172,13 @@ extern int fgetpwent_r (FILE *__restrict __stream,
 #ifdef __USE_GNU
 /* Re-construct the password-file line for the given uid
    in the given buffer.  This knows the format that the caller
-   will expect, but this need not be the format of the password file.  */
-extern int getpw (__uid_t __uid, char *__buffer) __THROW;
+   will expect, but this need not be the format of the password file.
+
+   This function is not part of POSIX and therefore no official
+   cancellation point.  But due to similarity with an POSIX interface
+   or due to the implementation it is a cancellation point and
+   therefore not marked with __THROW.  */
+extern int getpw (__uid_t __uid, char *__buffer);
 #endif
 
 __END_DECLS