This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch, master, updated. glibc-2.13-103-g1bfbe0d

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  1bfbe0d335d3fc44a492648b974a0db19975f6d8 (commit)
      from  0b592a30f5e3133bde98551fd524085359c3177a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------;a=commitdiff;h=1bfbe0d335d3fc44a492648b974a0db19975f6d8

commit 1bfbe0d335d3fc44a492648b974a0db19975f6d8
Author: Ulrich Drepper <>
Date:   Mon May 2 21:34:34 2011 -0400

    Better use of open in pathconf.

diff --git a/sysdeps/unix/sysv/linux/pathconf.c b/sysdeps/unix/sysv/linux/pathconf.c
index 375d672..52610a1 100644
--- a/sysdeps/unix/sysv/linux/pathconf.c
+++ b/sysdeps/unix/sysv/linux/pathconf.c
@@ -37,6 +37,7 @@ __pathconf (const char *file, int name)
   struct statfs fsbuf;
   int fd;
+  int flags;
   switch (name)
@@ -53,7 +54,11 @@ __pathconf (const char *file, int name)
       return __statfs_chown_restricted (__statfs (file, &fsbuf), &fsbuf);
     case _PC_PIPE_BUF:
-      fd = open_not_cancel_2 (file, O_RDONLY|O_NONBLOCK);
+#ifdef O_CLOEXEC
+      flags |= O_CLOEXEC;
+      fd = open_not_cancel_2 (file, flags);
       if (fd >= 0)
 	  long int r = __fcntl (fd, F_GETPIPE_SZ);


Summary of changes:
 sysdeps/unix/sysv/linux/pathconf.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

GNU C Library master sources

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]