]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - elf/chroot_canon.c
install.texi: Build was tested with binutils 2.41 (just released)
[thirdparty/glibc.git] / elf / chroot_canon.c
index 68c961d3c356855efacb1fbff413ee381ed78612..63a1ae6dbba759e7c55dfc540203e45d1b160ff0 100644 (file)
@@ -1,5 +1,5 @@
 /* Return the canonical absolute name of a given file inside chroot.
-   Copyright (C) 1996-2013 Free Software Foundation, Inc.
+   Copyright (C) 1996-2023 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    This program is free software; you can redistribute it and/or modify
@@ -13,7 +13,7 @@
    GNU General Public License for more details.
 
    You should have received a copy of the GNU General Public License
-   along with this program; if not, see <http://www.gnu.org/licenses/>.  */
+   along with this program; if not, see <https://www.gnu.org/licenses/>.  */
 
 #include <stdlib.h>
 #include <string.h>
@@ -67,7 +67,7 @@ chroot_canon (const char *chroot, const char *name)
 
   for (start = end = name; *start; start = end)
     {
-      struct stat64 st;
+      struct stat st;
 
       /* Skip sequence of multiple path-separators.  */
       while (*start == '/')
@@ -114,7 +114,7 @@ chroot_canon (const char *chroot, const char *name)
          dest = mempcpy (dest, start, end - start);
          *dest = '\0';
 
-         if (lstat64 (rpath, &st) < 0)
+         if (lstat (rpath, &st) < 0)
            {
              if (*end == '\0')
                goto done;