]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Revert "PR27345, binutils/arsup.c: lstat() not available on all targets"
authorNick Clifton <nickc@redhat.com>
Fri, 5 Feb 2021 14:08:16 +0000 (14:08 +0000)
committerNick Clifton <nickc@redhat.com>
Fri, 5 Feb 2021 14:08:16 +0000 (14:08 +0000)
This reverts commit c0034ac596db89dfb5fa007a63488ad7af555fe9.
Given the problems associated with this patch and the others intended to fix the smart_rename CVE, the decision has been taken to revert the patches for the 2.36.1 point release.

binutils/ChangeLog
binutils/arsup.c

index a568741661f304e2f8fc3e2070a08812608237fe..c53a4b5eb1e17c8ff389cf1e0ee4bbf5b3b94c48 100644 (file)
@@ -1,8 +1,3 @@
-2021-02-05  Alan Modra  <amodra@gmail.com>
-
-       PR 27345
-       * arsup.c (ar_save): Use stat rather than lstat.
-
 2021-02-03  Alan Modra  <amodra@gmail.com>
 
        PR 27270
index fa7706f79e502fb5ffc57f8b8e3a97e8480a1752..a60629f67618f16407cb0f409b9a3e9259013fdb 100644 (file)
@@ -357,7 +357,7 @@ ar_save (void)
 #endif
       bfd_close (obfd);
 
-      if (stat (real_name, &target_stat) != 0)
+      if (lstat (real_name, &target_stat) != 0)
        {
          /* The temp file created in ar_open has mode 0600 as per mkstemp.
             Create the real empty output file here so smart_rename will