This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch roland/nacl-port/master updated. 8638b8cc739ff7b775681d489c608e54a0883b39
- From: roland at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 2 May 2013 20:58:14 -0000
- Subject: GNU C Library master sources branch roland/nacl-port/master updated. 8638b8cc739ff7b775681d489c608e54a0883b39
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, roland/nacl-port/master has been updated
via 8638b8cc739ff7b775681d489c608e54a0883b39 (commit)
from 1b5fa03f65274e86a606931e8d47a596718a4756 (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=8638b8cc739ff7b775681d489c608e54a0883b39
commit 8638b8cc739ff7b775681d489c608e54a0883b39
Author: Roland McGrath <roland@hack.frob.com>
Date: Thu May 2 13:58:07 2013 -0700
Make sure stat calls diagnose EFAULT for a NULL struct stat *.
diff --git a/sysdeps/nacl/xstatconv.c b/sysdeps/nacl/xstatconv.c
index 6f4ccee..29f8427 100644
--- a/sysdeps/nacl/xstatconv.c
+++ b/sysdeps/nacl/xstatconv.c
@@ -24,6 +24,15 @@ internal_function
int
__xstat_conv (int vers, const struct nacl_abi_stat *kbuf, void *ubuf)
{
+ /* It's kosher enough just to crash here, but there are some
+ existing NaCl tests that like to see EFAULT, and that's what
+ making the IRT call with NULL would give. */
+ if (__glibc_unlikely (ubuf == NULL))
+ {
+ __set_errno (EFAULT);
+ return -1;
+ }
+
switch (vers)
{
case _STAT_VER_NACL:
-----------------------------------------------------------------------
Summary of changes:
sysdeps/nacl/xstatconv.c | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
hooks/post-receive
--
GNU C Library master sources