INtime SDK Help
utime

Sets the modification time for a file.

Note: This call is not available under INtime SDK version 5.
#include <sys/types.h>
#include <utime.h>

int utime (const char *filename, struct utimbuf *times);

Parameters

filename
File on which to set modification time. The process must have write access to the file.
times
Pointer to stored time values. If times is a NULL pointer, the modification time is set to the current time. Otherwise, times must point to a UTIMBUF structure, defined in sys\utime.h.

Remarks

The modification time is set from the modtime field in the UTIMBUF structure. Although this structure contains a field for access time, only the modification time is set.

Return Values

0 The file-modification time was changed.
-1 Time was unchanged and the function sets errno to one of these values:
EACCES Pathname specifies directory or read-only file.
EINVAL Invalid argument; the times argument is invalid.
EMFILE Too many open files (the file must be opened to change its modification time).
ENOENT Filename or pathname not found.

Requirements

Versions Defined in Include Link to
INtime 3.0 intime/rt/include/sys/utime.h sys/types.h
utime.h
clib.lib

See Also

asctime, ctime, gmtime, localtime, time