This is the mail archive of the glibc-cvs@sourceware.org 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.19-290-gfd15a59


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  fd15a59b20220a2d89d628ecebfcaad1ddefe871 (commit)
      from  f19dfa0afd3879cb09e9c6efd7df58e1ee02c029 (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 -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=fd15a59b20220a2d89d628ecebfcaad1ddefe871

commit fd15a59b20220a2d89d628ecebfcaad1ddefe871
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date:   Wed Apr 16 23:16:15 2014 +0200

    hurd: Do not allow unmapping address 0
    
    	* sysdeps/mach/munmap.c (__munmap): Return EINVAL if `addr' is 0.

diff --git a/ChangeLog b/ChangeLog
index ea70b28..970dedb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-04-16  Samuel Thibault  <samuel.thibault@ens-lyon.org>
+
+	* sysdeps/mach/munmap.c (__munmap): Return EINVAL if `addr' is 0.
+
 2014-04-16  Stefan Liebler  <stli@linux.vnet.ibm.com>
 
 	* sysdeps/s390/fpu/libm-test-ulps: Regenerate.
diff --git a/sysdeps/mach/munmap.c b/sysdeps/mach/munmap.c
index f8c416f..cfd5daa 100644
--- a/sysdeps/mach/munmap.c
+++ b/sysdeps/mach/munmap.c
@@ -27,6 +27,13 @@ int
 __munmap (__ptr_t addr, size_t len)
 {
   kern_return_t err;
+
+  if (addr == 0)
+    {
+      errno = EINVAL;
+      return -1;
+    }
+
   if (err = __vm_deallocate (__mach_task_self (),
 			     (vm_address_t) addr, (vm_size_t) len))
     {

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog             |    4 ++++
 sysdeps/mach/munmap.c |    7 +++++++
 2 files changed, 11 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
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]