[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug binutils/27456] Link failure due to the use of lstat in rename.c on
From: |
cvs-commit at gcc dot gnu.org |
Subject: |
[Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW |
Date: |
Tue, 23 Feb 2021 23:51:36 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=27456
--- Comment #8 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot
gnu.org> ---
The master branch has been updated by Alan Modra <amodra@sourceware.org>:
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=c42c71a1527dd70417d3966dce7ba9edbcf4bdb4
commit c42c71a1527dd70417d3966dce7ba9edbcf4bdb4
Author: Alan Modra <amodra@gmail.com>
Date: Tue Feb 23 12:10:58 2021 +1030
Use make_tempname file descriptor in smart_rename
This patch makes use of the temp file descriptor in smart_rename
rather than reopening the file. I don't believe there is a security
issue in reopening the file, but this way is one less directory
operation. The patch also attempts to preserve S_ISUID and S_ISGID.
PR 27456
* bucomm.h (smart_rename): Update prototype.
* rename.c (smart_rename): Add fromfd and preserve_dates params.
Pass fromfd and target_stat to simple_copy. Call set_times
when preserve_dates.
(simple_copy): Accept fromfd rather than from filename. Add
target_stat param. Rewind fromfd rather than opening. Open
"to" file without O_CREAT. Try to preserve S_ISUID and S_ISGID.
* ar.c (write_archive): Rename ofd to tmpfd. Dup tmpfd before
closing output temp file, and pass tmpfd to smart_rename.
* arsup.c (temp_fd): Rename from real_fd.
(ar_save): Dup temp_fd and pass to smart_rename.
* objcopy.c (strip_main, copy_main): Likewise, and pass
preserve_dates.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug binutils/27456] New: Link failure due to the use of lstat in rename.c on MinGW, markus.boeck02 at gmail dot com, 2021/02/22
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, amodra at gmail dot com, 2021/02/22
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, amodra at gmail dot com, 2021/02/22
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, markus.boeck02 at gmail dot com, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, markus.boeck02 at gmail dot com, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, amodra at gmail dot com, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, markus.boeck02 at gmail dot com, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, amodra at gmail dot com, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, cvs-commit at gcc dot gnu.org, 2021/02/23
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW,
cvs-commit at gcc dot gnu.org <=
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, pexu at sourceware dot mail.kapsi.fi, 2021/02/24
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, cvs-commit at gcc dot gnu.org, 2021/02/24
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, cvs-commit at gcc dot gnu.org, 2021/02/26
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, cvs-commit at gcc dot gnu.org, 2021/02/26
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, cvs-commit at gcc dot gnu.org, 2021/02/26
- [Bug binutils/27456] Link failure due to the use of lstat in rename.c on MinGW, amodra at gmail dot com, 2021/02/26