Author: adconrad
Date: 2013-05-07 20:40:47 +0000 (Tue, 07 May 2013)
New Revision: 5550

Modified:
   glibc-package/branches/eglibc-2.17/debian/changelog
   
glibc-package/branches/eglibc-2.17/debian/patches/any/unsubmitted-cloexec-conditional.diff
Log:
debian/patches/any/unsubmitted-cloexec-conditional.diff: Catch yet
another unconditional O_CLOEXEC and conditionalize it for freebsd.

Modified: glibc-package/branches/eglibc-2.17/debian/changelog
===================================================================
--- glibc-package/branches/eglibc-2.17/debian/changelog 2013-05-07 19:58:49 UTC 
(rev 5549)
+++ glibc-package/branches/eglibc-2.17/debian/changelog 2013-05-07 20:40:47 UTC 
(rev 5550)
@@ -1,6 +1,7 @@
 eglibc (2.17-2) UNRELEASED; urgency=low
 
-  * 
+  * debian/patches/any/unsubmitted-cloexec-conditional.diff: Catch yet
+    another unconditional O_CLOEXEC and conditionalize it for freebsd.
 
  -- Adam Conrad <[email protected]>  Tue, 07 May 2013 13:58:05 -0600
 

Modified: 
glibc-package/branches/eglibc-2.17/debian/patches/any/unsubmitted-cloexec-conditional.diff
===================================================================
--- 
glibc-package/branches/eglibc-2.17/debian/patches/any/unsubmitted-cloexec-conditional.diff
  2013-05-07 19:58:49 UTC (rev 5549)
+++ 
glibc-package/branches/eglibc-2.17/debian/patches/any/unsubmitted-cloexec-conditional.diff
  2013-05-07 20:40:47 UTC (rev 5550)
@@ -1,3 +1,20 @@
+diff --git a/elf/dl-load.c b/elf/dl-load.c
+index dd182c9..7ebb6ff 100644
+--- a/elf/dl-load.c
++++ b/elf/dl-load.c
+@@ -1721,7 +1721,11 @@ open_verify (const char *name, struct filebuf *fbp, 
struct link_map *loader,
+ #endif
+ 
+   /* Open the file.  We always open files read-only.  */
+-  int fd = __open (name, O_RDONLY | O_CLOEXEC);
++  int oflags = O_RDONLY;
++#ifdef O_CLOEXEC
++  oflags |= O_CLOEXEC;
++#endif
++  int fd = __open (name, oflags);
+   if (fd != -1)
+     {
+       ElfW(Ehdr) *ehdr;
 diff --git a/libio/fileops.c b/libio/fileops.c
 index 61b61b3..80767f5 100644
 --- a/libio/fileops.c


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]
Archive: http://lists.debian.org/[email protected]

Reply via email to