diff options
author | Thomas Jarosch <thomas.jarosch@intra2net.com> | 2011-10-29 12:24:38 -0400 |
---|---|---|
committer | Ulrich Drepper <drepper@gmail.com> | 2011-10-29 12:24:38 -0400 |
commit | 1760874da6e4a6934751ea12cf2c06eae936b53c (patch) | |
tree | c38588e3cc48868e9e0660703d32ee45a8c0d113 /elf | |
parent | 51d91b18954c998ccda310231f4d120f21a5fd79 (diff) | |
download | glibc-1760874da6e4a6934751ea12cf2c06eae936b53c.zip glibc-1760874da6e4a6934751ea12cf2c06eae936b53c.tar.gz glibc-1760874da6e4a6934751ea12cf2c06eae936b53c.tar.bz2 |
Fix readlink call in ldconfig's chroot handling
Diffstat (limited to 'elf')
-rw-r--r-- | elf/chroot_canon.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/elf/chroot_canon.c b/elf/chroot_canon.c index 54a6a4c..b639cfa 100644 --- a/elf/chroot_canon.c +++ b/elf/chroot_canon.c @@ -1,5 +1,5 @@ /* Return the canonical absolute name of a given file inside chroot. - Copyright (C) 1996,1997,1998,1999,2000,2001,2004,2005,2010 + Copyright (C) 1996,1997,1998,1999,2000,2001,2004,2005,2010,2011 Free Software Foundation, Inc. This file is part of the GNU C Library. @@ -135,7 +135,7 @@ chroot_canon (const char *chroot, const char *name) goto error; } - n = readlink (rpath, buf, PATH_MAX); + n = readlink (rpath, buf, PATH_MAX - 1); if (n < 0) { if (*end == '\0') |