[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

r5989 - in glibc-package/branches/eglibc-2.19/debian: . patches patches/hurd-i386



Author: sthibault
Date: 2014-03-04 01:18:09 +0000 (Tue, 04 Mar 2014)
New Revision: 5989

Added:
   glibc-package/branches/eglibc-2.19/debian/patches/hurd-i386/tg-mmap_file_prot_none_fix.diff
Modified:
   glibc-package/branches/eglibc-2.19/debian/changelog
   glibc-package/branches/eglibc-2.19/debian/patches/series
Log:
Merge from trunk


Modified: glibc-package/branches/eglibc-2.19/debian/changelog
===================================================================
--- glibc-package/branches/eglibc-2.19/debian/changelog	2014-03-04 01:16:03 UTC (rev 5988)
+++ glibc-package/branches/eglibc-2.19/debian/changelog	2014-03-04 01:18:09 UTC (rev 5989)
@@ -59,6 +59,14 @@
 
  -- Adam Conrad <adconrad@0c3.net>  Sun, 09 Feb 2014 09:46:13 -0700
 
+eglibc (2.18-5) UNRELEASED; urgency=high
+
+  [ Samuel Thibault ]
+  * patches/hurd-i386/tg-mmap_file_prot_none_fix.diff: New patch, fixes locale
+    generation.
+
+  -- Aurelien Jarno <aurel32@debian.org>  Sun, 02 Mar 2014 16:19:49 +0100
+
 eglibc (2.18-4) unstable; urgency=high
 
   [ Aurelien Jarno ]

Copied: glibc-package/branches/eglibc-2.19/debian/patches/hurd-i386/tg-mmap_file_prot_none_fix.diff (from rev 5988, glibc-package/trunk/debian/patches/hurd-i386/tg-mmap_file_prot_none_fix.diff)
===================================================================
--- glibc-package/branches/eglibc-2.19/debian/patches/hurd-i386/tg-mmap_file_prot_none_fix.diff	                        (rev 0)
+++ glibc-package/branches/eglibc-2.19/debian/patches/hurd-i386/tg-mmap_file_prot_none_fix.diff	2014-03-04 01:18:09 UTC (rev 5989)
@@ -0,0 +1,40 @@
+From: Richard Braun <rbraun@sceen.net>
+Subject: [PATCH] t/mmap_file_prot_none_fix
+
+Allow mmap to handle mapping requests on files despite protection set to
+PROT_NONE.
+
+---
+ sysdeps/mach/hurd/mmap.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/sysdeps/mach/hurd/mmap.c b/sysdeps/mach/hurd/mmap.c
+index 6ee3146..b947815 100644
+--- a/sysdeps/mach/hurd/mmap.c
++++ b/sysdeps/mach/hurd/mmap.c
+@@ -97,6 +97,14 @@ __mmap (__ptr_t addr, size_t len, int prot, int flags, int fd, off_t offset)
+ 	  }
+ 	switch (prot & (PROT_READ|PROT_WRITE))
+ 	  {
++	  /* Although it apparently doesn't make sense to map a file with
++	     protection set to PROT_NONE, it is actually sometimes done.
++	     In particular, that's how localedef reserves some space for
++	     the locale archive file, the rationale being that some
++	     implementations take into account whether the mapping is
++	     anonymous or not when selecting addresses.  */
++	  case PROT_NONE:
++
+ 	  case PROT_READ:
+ 	    memobj = robj;
+ 	    if (wobj != MACH_PORT_NULL)
+@@ -126,8 +134,6 @@ __mmap (__ptr_t addr, size_t len, int prot, int flags, int fd, off_t offset)
+ 		return (__ptr_t) (long int) __hurd_fail (EACCES);
+ 	      }
+ 	    break;
+-	  default:		/* impossible */
+-	    return 0;
+ 	  }
+ 	break;
+ 	/* XXX handle MAP_NOEXTEND */
+-- 
+tg: (9a079e2..) t/mmap_file_prot_none_fix (depends on: baseline)

Modified: glibc-package/branches/eglibc-2.19/debian/patches/series
===================================================================
--- glibc-package/branches/eglibc-2.19/debian/patches/series	2014-03-04 01:16:03 UTC (rev 5988)
+++ glibc-package/branches/eglibc-2.19/debian/patches/series	2014-03-04 01:18:09 UTC (rev 5989)
@@ -126,6 +126,7 @@
 hurd-i386/tg-sigstate_locking.diff
 hurd-i386/tg-sigstate_thread_reference.diff
 hurd-i386/tg-tls_thread_leak.diff
+hurd-i386/tg-mmap_file_prot_none_fix.diff
 
 i386/local-biarch.diff
 i386/local-cmov.diff


Reply to: