2006-05-02 00:05:35 +00:00
|
|
|
.\" Hey Emacs! This file is -*- nroff -*- source.
|
|
|
|
.\"
|
|
|
|
.\" This manpage is Copyright (C) 2006, Michael Kerrisk
|
|
|
|
.\"
|
|
|
|
.\" Permission is granted to make and distribute verbatim copies of this
|
|
|
|
.\" manual provided the copyright notice and this permission notice are
|
|
|
|
.\" preserved on all copies.
|
|
|
|
.\"
|
|
|
|
.\" Permission is granted to copy and distribute modified versions of this
|
|
|
|
.\" manual under the conditions for verbatim copying, provided that the
|
|
|
|
.\" entire resulting derived work is distributed under the terms of a
|
|
|
|
.\" permission notice identical to this one.
|
2007-04-12 22:42:49 +00:00
|
|
|
.\"
|
2006-05-02 00:05:35 +00:00
|
|
|
.\" Since the Linux kernel and libraries are constantly changing, this
|
|
|
|
.\" manual page may be incorrect or out-of-date. The author(s) assume no
|
|
|
|
.\" responsibility for errors or omissions, or for damages resulting from
|
|
|
|
.\" the use of the information contained herein. The author(s) may not
|
|
|
|
.\" have taken the same level of care in the production of this manual,
|
|
|
|
.\" which is licensed free of charge, as they might when working
|
|
|
|
.\" professionally.
|
2007-04-12 22:42:49 +00:00
|
|
|
.\"
|
2006-05-02 00:05:35 +00:00
|
|
|
.\" Formatted or processed versions of this manual, if unaccompanied by
|
|
|
|
.\" the source, must acknowledge the copyright and authors of this work.
|
|
|
|
.\"
|
|
|
|
.\"
|
futimesat.2, mount.2, confstr.3, iconv.3, makedev.3, malloc.3, strcasecmp.3, strcat.3, strcmp.3, strcpy.3, strdup.3, strftime.3, strnlen.3, strpbrk.3, strspn.3, strtok.3, strxfrm.3, sk98lin.4, icmp.7, ipv6.7, packet.7, raw.7, rtnetlink.7, unix.7, x25.7, ldconfig.8, nscd.8: tstamp
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-10 20:09:28 +00:00
|
|
|
.TH FUTIMESAT 2 2012-05-10 "Linux" "Linux Programmer's Manual"
|
2006-05-02 00:05:35 +00:00
|
|
|
.SH NAME
|
2007-05-11 23:07:02 +00:00
|
|
|
futimesat \- change timestamps of a file relative to a \
|
2006-05-02 00:05:35 +00:00
|
|
|
directory file descriptor
|
|
|
|
.SH SYNOPSIS
|
|
|
|
.nf
|
2007-10-08 18:45:41 +00:00
|
|
|
.B #include <fcntl.h> /* Definition of AT_* constants */
|
2012-03-24 10:26:52 +00:00
|
|
|
.B #include <sys/time.h>
|
2006-05-02 00:05:35 +00:00
|
|
|
.sp
|
2007-04-12 22:42:49 +00:00
|
|
|
.BI "int futimesat(int " dirfd ", const char *" pathname ,
|
2006-05-02 00:05:35 +00:00
|
|
|
.BI " const struct timeval " times [2]);
|
|
|
|
.fi
|
faccessat.2, fchmodat.2, fchownat.2, fstatat.2, futimesat.2, linkat.2, mkdirat.2, mknodat.2, openat.2, readlinkat.2, renameat.2, symlinkat.2, unlinkat.2, utimensat.2, mkfifoat.3: Update feature test macro requirements
Starting in glibc 2.10, defining _XOPEN_SOURCE >= 700,
or _POSIX_C_SOURCE >= 200809 exposes the declarations of
these functions.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2009-12-13 21:54:45 +00:00
|
|
|
.sp
|
|
|
|
.in -4n
|
|
|
|
Feature Test Macro Requirements for glibc (see
|
|
|
|
.BR feature_test_macros (7)):
|
|
|
|
.in
|
|
|
|
.sp
|
|
|
|
.BR futimesat ():
|
2012-03-24 10:26:52 +00:00
|
|
|
_GNU_SOURCE
|
2006-05-02 00:05:35 +00:00
|
|
|
.SH DESCRIPTION
|
2008-06-02 14:12:37 +00:00
|
|
|
This system call is obsolete.
|
|
|
|
Use
|
|
|
|
.BR utimensat (2)
|
|
|
|
instead.
|
|
|
|
|
2006-05-02 00:05:35 +00:00
|
|
|
The
|
|
|
|
.BR futimesat ()
|
|
|
|
system call operates in exactly the same way as
|
|
|
|
.BR utimes (2),
|
|
|
|
except for the differences described in this manual page.
|
|
|
|
|
2007-04-12 22:42:49 +00:00
|
|
|
If the pathname given in
|
2006-05-02 00:05:35 +00:00
|
|
|
.I pathname
|
|
|
|
is relative, then it is interpreted relative to the directory
|
|
|
|
referred to by the file descriptor
|
2007-09-20 16:26:31 +00:00
|
|
|
.I dirfd
|
2007-04-12 22:42:49 +00:00
|
|
|
(rather than relative to the current working directory of
|
2006-05-02 00:05:35 +00:00
|
|
|
the calling process, as is done by
|
|
|
|
.BR utimes (2)
|
|
|
|
for a relative pathname).
|
|
|
|
|
2006-08-09 09:08:01 +00:00
|
|
|
If
|
2006-05-02 00:05:35 +00:00
|
|
|
.I pathname
|
2007-04-12 22:42:49 +00:00
|
|
|
is relative and
|
2006-05-02 00:05:35 +00:00
|
|
|
.I dirfd
|
|
|
|
is the special value
|
|
|
|
.BR AT_FDCWD ,
|
|
|
|
then
|
|
|
|
.I pathname
|
2007-04-12 22:42:49 +00:00
|
|
|
is interpreted relative to the current working
|
2006-05-02 00:05:35 +00:00
|
|
|
directory of the calling process (like
|
|
|
|
.BR utimes (2)).
|
|
|
|
|
2006-08-09 09:08:01 +00:00
|
|
|
If
|
2007-09-20 16:26:31 +00:00
|
|
|
.I pathname
|
2007-04-12 22:42:49 +00:00
|
|
|
is absolute, then
|
|
|
|
.I dirfd
|
2006-05-02 00:05:35 +00:00
|
|
|
is ignored.
|
|
|
|
.SH "RETURN VALUE"
|
|
|
|
On success,
|
2007-04-12 22:42:49 +00:00
|
|
|
.BR futimesat ()
|
2006-05-02 00:05:35 +00:00
|
|
|
returns a 0.
|
|
|
|
On error, \-1 is returned and
|
|
|
|
.I errno
|
|
|
|
is set to indicate the error.
|
|
|
|
.SH ERRORS
|
|
|
|
The same errors that occur for
|
|
|
|
.BR utimes (2)
|
|
|
|
can also occur for
|
|
|
|
.BR futimesat ().
|
2007-04-12 22:42:49 +00:00
|
|
|
The following additional errors can occur for
|
2006-05-02 00:05:35 +00:00
|
|
|
.BR futimesat ():
|
|
|
|
.TP
|
|
|
|
.B EBADF
|
|
|
|
.I dirfd
|
|
|
|
is not a valid file descriptor.
|
|
|
|
.TP
|
|
|
|
.B ENOTDIR
|
|
|
|
.I pathname
|
2006-08-08 16:34:16 +00:00
|
|
|
is relative and
|
2006-05-02 00:05:35 +00:00
|
|
|
.I dirfd
|
|
|
|
is a file descriptor referring to a file other than a directory.
|
2007-05-18 16:06:42 +00:00
|
|
|
.SH VERSIONS
|
|
|
|
.BR futimesat ()
|
faccessat.2, fchmodat.2, fchownat.2, fstatat.2, futimesat.2, inotify_init.2, linkat.2, mkdirat.2, mknodat.2, openat.2, readlinkat.2, renameat.2, setns.2, splice.2, symlinkat.2, sync.2, tee.2, unlinkat.2, vmsplice.2: Global fix: note glibc version that added library support
Reported-by: Lauri Kasanen <curaga@operamail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2012-05-04 04:09:11 +00:00
|
|
|
was added to Linux in kernel 2.6.16;
|
|
|
|
library support was added to glibc in version 2.4.
|
2006-05-02 00:05:35 +00:00
|
|
|
.SH "CONFORMING TO"
|
accept.2, execve.2, futimesat.2, getresuid.2, getrlimit.2, madvise.2, mq_getsetattr.2, msgctl.2, nice.2, open.2, poll.2, setresuid.2, shmctl.2, sigaction.2, times.2, utimensat.2, __setfpucw.3, atoi.3, endian.3, err.3, euidaccess.3, fenv.3, fopencookie.3, fpurge.3, getgrouplist.3, getutmp.3, j0.3, lgamma.3, netlink.3, pthread_attr_init.3, pthread_attr_setaffinity_np.3, pthread_cleanup_push_defer_np.3, pthread_getattr_np.3, pthread_kill_other_threads_np.3, pthread_setaffinity_np.3, pthread_tryjoin_np.3, pthread_yield.3, random_r.3, readdir.3, rtnetlink.3, scanf.3, setenv.3, significand.3, sigsetops.3, strerror.3, strstr.3, sysv_signal.3, termios.3, timegm.3, unlocked_stdio.3, y0.3, locale.5, bootparam.7, feature_test_macros.7, ip.7, locale.7, pthreads.7, rtld-audit.7, nscd.8: Global fix: s/non-standard/nonstandard/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 16:37:52 +00:00
|
|
|
This system call is nonstandard.
|
2008-09-18 12:30:37 +00:00
|
|
|
It was implemented from a specification that was proposed for POSIX.1,
|
2008-06-02 14:12:37 +00:00
|
|
|
but that specification was replaced by the one for
|
2008-06-03 12:24:19 +00:00
|
|
|
.BR utimensat (2).
|
2008-06-02 14:12:37 +00:00
|
|
|
|
2006-05-02 00:05:35 +00:00
|
|
|
A similar system call exists on Solaris.
|
2007-05-18 10:30:02 +00:00
|
|
|
.SH NOTES
|
intro.1, time.1, _syscall.2, accept.2, brk.2, capget.2, faccessat.2, futimesat.2, gethostname.2, intro.2, ioprio_set.2, kill.2, madvise.2, mlock.2, mount.2, msgget.2, perf_event_open.2, poll.2, readv.2, sched_rr_get_interval.2, sched_setscheduler.2, select.2, select_tut.2, shmget.2, stat.2, timer_create.2, ustat.2, vfork.2, wait.2, alloca.3, atexit.3, catopen.3, crypt.3, dbopen.3, fenv.3, fopen.3, getaddrinfo_a.3, gethostbyname.3, getutent.3, intro.3, login.3, mallopt.3, queue.3, regex.3, sigpause.3, sigsetops.3, stdio.3, strftime.3, strptime.3, sysconf.3, ttyslot.3, undocumented.3, cciss.4, console_codes.4, hpsa.4, initrd.4, intro.4, rtc.4, st.4, tty_ioctl.4, wavelan.4, acct.5, charmap.5, dir_colors.5, hosts.5, intro.5, termcap.5, utmp.5, intro.6, armscii-8.7, boot.7, bootparam.7, capabilities.7, cpuset.7, credentials.7, ddp.7, epoll.7, glob.7, intro.7, ip.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man-pages.7, man.7, math_error.7, netlink.7, numa.7, packet.7, path_resolution.7, pipe.7, pthreads.7, raw.7, rtnetlink.7, signal.7, socket.7, spufs.7, svipc.7, tcp.7, time.7, udp.7, udplite.7, unicode.7, unix.7, uri.7, utf-8.7, x25.7, intro.8: Global fix: use consistent capitalization in .SS headings
Capitalization in .SS sections across pages (and sometimes even
within a single page) is wildly inconsistent. Make it consistent.
Capitalize first word in heading, but otherwise use lower case,
except where English usage (e.g., proper nouns) or programming
language requirements (e.g., identifier names) dictate otherwise.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 14:08:38 +00:00
|
|
|
.SS Glibc notes
|
2006-08-09 09:08:01 +00:00
|
|
|
If
|
|
|
|
.I pathname
|
2007-04-12 22:42:49 +00:00
|
|
|
is NULL, then the glibc
|
2007-05-11 23:07:02 +00:00
|
|
|
.BR futimesat ()
|
2006-05-02 00:05:35 +00:00
|
|
|
wrapper function updates the times for the file referred to by
|
|
|
|
.IR dirfd .
|
|
|
|
.\" The Solaris futimesat() also has this strangeness.
|
|
|
|
.SH "SEE ALSO"
|
|
|
|
.BR stat (2),
|
2008-06-02 14:12:37 +00:00
|
|
|
.BR utimensat (2),
|
2006-05-02 00:05:35 +00:00
|
|
|
.BR utimes (2),
|
2007-06-01 05:25:11 +00:00
|
|
|
.BR futimes (3),
|
2007-05-26 12:41:39 +00:00
|
|
|
.BR path_resolution (7)
|