Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ utimes(2) — UTek W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

stat(2)



UTIMES(2)               COMMAND REFERENCE               UTIMES(2)



NAME
     utimes - set file times

SYNOPSIS
     #include <sys/time.h>

     utimes(path, tvp)
     char *path;
     struct timeval tvp[2];

DESCRIPTION
     The utimes call uses the values in the tvp array to set the
     "accessed" and "modified" times (in that order) for the file
     named by path. The timeval structure is defined in
     <sys/time.h> as:

          struct timeval {
               long tv_sec;   /* seconds */
               long tv_usec;  /* and microseconds */
          };

     The caller must be the owner of the file or the super-user.
     The "inode-changed" time of the file is set to the current
     time.

DIAGNOSTICS
     Utimes will fail if one or more of the following are true:

     [ENOASCII]
         The pathname contains a character with the high-order
         bit set.

     [ENAMETOOLONG]
         The pathname is too long.

     [ENOENT]
         The named file does not exist.

     [ENOTDIR]
         A component of the path prefix is not a directory.

     [EIO]
         An I/O error occurred while reading from or writing to
         the file system.

     [EACCES]
         A component of the path prefix denies search permission.
         If the file is located on a remote host, this error code
         will be returned if the local host name and local user
         name does not appear in /usr/lib/dfs/access on the
         remote machine.  See access(dfs)(5n).




Printed 10/17/86                                                1





UTIMES(2)               COMMAND REFERENCE               UTIMES(2)



     [EPERM]
         The process is not super-user and not the owner of the
         file.

     [EROFS]
         The file system containing the file is mounted read-
         only.

     [EFAULT]
         File or tvp points outside the process's allocated
         address space.

     [ELOOP]
         Too many symbolic links were encountered in translating
         the pathname.

     [EDFSNOSUCHHOST]
         The pathname referenced a remote host, but when we
         broadcast a request for its address, no host responded.

RETURN VALUE
     Upon successful completion, a value of 0 is returned.
     Otherwise, a value of -1 is returned and errno is set to
     indicate the error.

SEE ALSO
     stat(2).




























Printed 10/17/86                                                2





































































%%index%%
na:72,59;
sy:131,550;
de:681,631;
di:1312,926;2382,547;
rv:2929,236;
se:3165,100;
%%index%%000000000115

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026