summaryrefslogtreecommitdiff
path: root/binutils/arsup.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2021-02-05 12:59:16 +1030
committerAlan Modra <amodra@gmail.com>2021-02-05 13:04:29 +1030
commitc180f095f32ca62f138da9bc7fb96cac0365fb5d (patch)
tree4e1ab7a50628d25858501e1ee17ee9ea5f385dfb /binutils/arsup.c
parent04b4939b0362686e7b3ebb531edb0bbd37a59a1b (diff)
downloadbinutils-gdb-c180f095f32ca62f138da9bc7fb96cac0365fb5d.tar.gz
PR27345, binutils/arsup.c: lstat() not available on all targets
We can just use stat here, the same as is done in ar.c:open_inarch. PR 27345 * arsup.c (ar_save): Use stat rather than lstat.
Diffstat (limited to 'binutils/arsup.c')
-rw-r--r--binutils/arsup.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/binutils/arsup.c b/binutils/arsup.c
index a60629f6761..fa7706f79e5 100644
--- a/binutils/arsup.c
+++ b/binutils/arsup.c
@@ -357,7 +357,7 @@ ar_save (void)
#endif
bfd_close (obfd);
- if (lstat (real_name, &target_stat) != 0)
+ if (stat (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