touch(3)
limb manual
touch(3)
NAME
touch - update a file's atime & mtime timestamps
SYNOPSIS
#include <limb/posixplz.h>
int touch(const char *file)
DESCRIPTION
The touch
() function will update both the atime
and mtime
timestamps of
the file named file
, creating it if it doesn't exist.
RETURN VALUE
The touch
() function returns 1 on success. Otherwise it returns 0 and sets
errno
to indicate the error.
ERRORS
The touch
() function may fail for any of the errors described for
open_create(3).
It may also fail and set errno
for the errors described for futimens(3),
futimes(3) or utimes(3) depending on what's available on the system.
Note
The availability of functions is determined at compile-time, during the compilation of skalibs.