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.12-7-g5d05c55


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  5d05c55424406c947618d60f06fc0d119a4f0e54 (commit)
       via  1f6234dcd8cdb2dba2145b2c87dc58a934b60597 (commit)
       via  5ae958d74180e2572d198bd7872c86f391de6da7 (commit)
      from  70c9476e834802806e327882f4530e10555cb3a8 (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://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=5d05c55424406c947618d60f06fc0d119a4f0e54

commit 5d05c55424406c947618d60f06fc0d119a4f0e54
Merge: 1f6234d 70c9476
Author: Ulrich Drepper <drepper@redhat.com>
Date:   Wed May 5 09:48:21 2010 -0700

    Merge branch 'master' of ssh://sources.redhat.com/git/glibc

diff --cc ChangeLog
index 0d3d04a,bdbf33b..e379606
--- a/ChangeLog
+++ b/ChangeLog
@@@ -1,9 -1,9 +1,13 @@@
+ 2010-05-05  Andreas Schwab  <schwab@redhat.com>
+ 
+ 	* INSTALL: Regenerate.
+ 
  2010-05-05  Ulrich Drepper  <drepper@redhat.com>
  
 +	[BZ #11571]
 +	* sysdeps/unix/sysv/linux/getlogin_r.c (__getlogin_r_loginuid): Handle
 +	too small buffers according to the standard.
 +
  	* sysdeps/unix/sysv/linux/kernel-features.h: Alpha doesn't have to be
  	handled here anymore.
  	Patch mostly by Matt Turner <mattst88@gmail.com>.

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=1f6234dcd8cdb2dba2145b2c87dc58a934b60597

commit 1f6234dcd8cdb2dba2145b2c87dc58a934b60597
Author: Andreas Schwab <schwab@redhat.com>
Date:   Wed May 5 09:47:25 2010 -0700

    Fix name of tt_RU.UTF-8@iqtelif locale.

diff --git a/localedata/ChangeLog b/localedata/ChangeLog
index 514be38..5a0fb7a 100644
--- a/localedata/ChangeLog
+++ b/localedata/ChangeLog
@@ -1,3 +1,8 @@
+2010-05-04  Andreas Schwab  <schwab@redhat.com>
+
+	* SUPPORTED (SUPPORTED-LOCALES): Fix name of tt_RU.UTF-8@iqtelif
+	locale.
+
 2010-05-03  Ulrich Drepper  <drepper@redhat.com>
 
 	[BZ #11520]
diff --git a/localedata/SUPPORTED b/localedata/SUPPORTED
index a1ebcac..d665961 100644
--- a/localedata/SUPPORTED
+++ b/localedata/SUPPORTED
@@ -386,7 +386,7 @@ tr_TR.UTF-8/UTF-8 \
 tr_TR/ISO-8859-9 \
 ts_ZA/UTF-8 \
 tt_RU.UTF-8/UTF-8 \
-tt_RU@iqtelif.UTF-8/UTF-8 \
+tt_RU.UTF-8@iqtelif/UTF-8 \
 ug_CN/UTF-8 \
 uk_UA.UTF-8/UTF-8 \
 uk_UA/KOI8-U \

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=5ae958d74180e2572d198bd7872c86f391de6da7

commit 5ae958d74180e2572d198bd7872c86f391de6da7
Author: Ulrich Drepper <drepper@redhat.com>
Date:   Wed May 5 09:44:50 2010 -0700

    Handle too-small buffers in Linux getlogin_r.

diff --git a/ChangeLog b/ChangeLog
index a7fdafa..0d3d04a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2010-05-05  Ulrich Drepper  <drepper@redhat.com>
 
+	[BZ #11571]
+	* sysdeps/unix/sysv/linux/getlogin_r.c (__getlogin_r_loginuid): Handle
+	too small buffers according to the standard.
+
 	* sysdeps/unix/sysv/linux/kernel-features.h: Alpha doesn't have to be
 	handled here anymore.
 	Patch mostly by Matt Turner <mattst88@gmail.com>.
diff --git a/NEWS b/NEWS
index f508959..c0c74be 100644
--- a/NEWS
+++ b/NEWS
@@ -16,7 +16,7 @@ Version 2.12
   11185, 11186, 11187, 11188, 11189, 11190, 11191, 11192, 11193, 11194,
   11200, 11230, 11235, 11242, 11254, 11258, 11271, 11272, 11276, 11279,
   11287, 11292, 11319, 11332, 11333, 11387, 11389, 11390, 11394, 11397,
-  11410, 11438, 11449, 11470, 11471, 11520, 11537, 11538
+  11410, 11438, 11449, 11470, 11471, 11520, 11537, 11538, 11571
 
 * New interfaces: pthread_getname_np, pthread_setname_np
 
diff --git a/sysdeps/unix/sysv/linux/getlogin_r.c b/sysdeps/unix/sysv/linux/getlogin_r.c
index d9c66fe..dad2671 100644
--- a/sysdeps/unix/sysv/linux/getlogin_r.c
+++ b/sysdeps/unix/sysv/linux/getlogin_r.c
@@ -81,13 +81,22 @@ __getlogin_r_loginuid (name, namesize)
   if (tpwd == NULL)
     goto fail;
 
-  strncpy (name, pwd.pw_name, namesize - 1);
-  name[namesize - 1] = '\0';
-
+  int result = 0;
+  size_t needed = strlen (pwd.pw_name) + 1;
+  if (needed > namesize)
+    {
+      __set_errno (ERANGE);
+      result = ERANGE;
+      goto out;
+    }
+
+  memcpy (name, pwd.pw_name, needed);
+
+ out:
   if (use_malloc)
     free (buf);
 
-  return 0;
+  return result;
 }
 
 

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

Summary of changes:
 ChangeLog                            |    4 ++++
 NEWS                                 |    2 +-
 localedata/ChangeLog                 |    5 +++++
 localedata/SUPPORTED                 |    2 +-
 sysdeps/unix/sysv/linux/getlogin_r.c |   17 +++++++++++++----
 5 files changed, 24 insertions(+), 6 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]