emacs/m4
Paul Eggert 5d4cf1fef8 Add ‘nofollow’ flag to set-file-times
This is a companion to the recent set-file-modes patch.
It adds support for a ‘nofollow’ flag to set-file-times (Bug#39773).
Like the set-file-modes patch, it needs work in the w32 port.
* admin/merge-gnulib (GNULIB_MODULES): Add futimens, utimensat.
Remove utimens.
* doc/lispref/files.texi (Changing Files):
* etc/NEWS: Mention the change.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* lisp/files.el (copy-directory):
* lisp/gnus/gnus-cloud.el (gnus-cloud-replace-file):
* lisp/net/tramp-adb.el (tramp-adb-handle-copy-file):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-file):
* lisp/tar-mode.el (tar-copy):
* test/lisp/filenotify-tests.el (file-notify-test03-events):
* test/lisp/files-tests.el:
(files-tests-file-name-non-special-set-file-times):
* test/lisp/net/tramp-tests.el (tramp-test22-file-times):
When setting file times, avoid following symbolic links
when the file is not supposed to be a symbolic link.
* lib/futimens.c, lib/utimensat.c, m4/futimens.m4, m4/utimensat.m4:
New files, copied from Gnulib.
* lisp/gnus/gnus-cloud.el (gnus-cloud-replace-file):
When creating a file that is not supposed to exist already,
use the excl flag to check this.
* lisp/net/tramp-adb.el (tramp-adb-handle-set-file-times):
* lisp/net/tramp-sh.el (tramp-sh-handle-set-file-times):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-set-file-times):
Accept an optional FLAG arg that is currently ignored,
and add a FIXME comment for it.
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-set-file-times):
* src/fileio.c (Fset_file_times):
Support an optional FLAG arg.
* src/fileio.c (Fcopy_file): Use futimens instead of set_file_times,
as it’s simpler and is a POSIX API.
* src/sysdep.c (set_file_times): Move from here ...
* src/w32.c (set_file_times): ... to here, and make it static,
since it is now used only in w32.c.  Presumably w32.c should also
add support for futimens and utimensat (the POSIX APIs, which
Emacs now uses) and it can remove fdutimens (the Gnulib API,
which Emacs no longer uses).
2020-03-07 12:15:43 -08:00
..
00gnulib.m4 Update from Gnulib 2020-01-18 20:55:09 -08:00
__inline.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
absolute-header.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
acl.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
alloca.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
builtin-expect.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
byteswap.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
canonicalize.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
clock_time.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
close-stream.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
copy-file-range.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
d-type.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
dirent_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
dirfd.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
double-slash-root.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
dup2.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
eealloc.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
environ.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
errno_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
euidaccess.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
execinfo.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
explicit_bzero.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
extensions.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
extern-inline.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
faccessat.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fchmodat.m4 Add 'nofollow' flag to set-file-modes etc. 2020-02-23 16:45:50 -08:00
fcntl.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fcntl_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fdopendir.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
filemode.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
flexmember.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fpending.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fpieee.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fstatat.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
fsusage.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
fsync.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
futimens.m4 Add ‘nofollow’ flag to set-file-times 2020-03-07 12:15:43 -08:00
getdtablesize.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
getgroups.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
getloadavg.m4 Update from Gnulib 2020-02-24 17:55:39 -08:00
getopt.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
gettime.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
gettimeofday.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
glibc21.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
gnulib-common.m4 Update from Gnulib 2020-02-09 00:45:42 -08:00
gnulib-comp.m4 Add ‘nofollow’ flag to set-file-times 2020-03-07 12:15:43 -08:00
group-member.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
ieee754-h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
include_next.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
inttypes.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
largefile.m4 Update from Gnulib 2020-02-22 10:33:45 -08:00
lchmod.m4 Add 'nofollow' flag to set-file-modes etc. 2020-02-23 16:45:50 -08:00
limits-h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
localtime-buffer.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
lstat.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
malloca.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
manywarnings.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
mbstate_t.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
md5.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
memmem.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
mempcpy.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
memrchr.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
minmax.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
mkostemp.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
mktime.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
mode_t.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
multiarch.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
nocrash.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
nstrftime.m4 Update from Gnulib 2020-02-23 16:15:01 -08:00
off_t.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
open-cloexec.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
open-slash.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
open.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
pathmax.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
pipe2.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
pkg.m4 Merge from pkg-config 2018-02-11 13:10:41 -08:00
pselect.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
pthread_sigmask.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
readlink.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
readlinkat.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
regex.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sha1.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sha256.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sha512.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sig2str.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
signal_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
socklen.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
ssize_t.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
st_dm_mode.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
stat-time.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
std-gnu11.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
stdalign.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
stddef_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
stdint.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
stdio_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
stdlib_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
stpcpy.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
string_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
strnlen.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
strtoimax.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
strtoll.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
symlink.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sys_select_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sys_socket_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
sys_stat_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
sys_time_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sys_types_h.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
tempname.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
time_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
time_r.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
time_rz.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
timegm.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
timer_time.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
timespec.m4 Update from gnulib 2019-12-31 19:11:56 -08:00
tm_gmtoff.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
unistd_h.m4 Update from Gnulib 2020-02-23 01:27:19 -08:00
unlocked-io.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
utimens.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
utimensat.m4 Add ‘nofollow’ flag to set-file-times 2020-03-07 12:15:43 -08:00
utimes.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
vararrays.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
warnings.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
wchar_t.m4 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
zzgnulib.m4 Update from Gnulib 2020-01-18 20:55:09 -08:00