11 __weak_alias(utimes
, __utimes50
)
14 int utimes(const char *name
, const struct timeval tv
[2])
22 if (name
[0] == '\0') { /* X/Open requirement */
26 memset(&m
, 0, sizeof(m
));
27 m
.m_vfs_utimens
.len
= strlen(name
) + 1;
28 m
.m_vfs_utimens
.name
= __UNCONST(name
);
30 m
.m_vfs_utimens
.atime
= m
.m_vfs_utimens
.mtime
= 0;
31 m
.m_vfs_utimens
.ansec
= m
.m_vfs_utimens
.mnsec
= UTIME_NOW
;
34 m
.m_vfs_utimens
.atime
= tv
[0].tv_sec
;
35 m
.m_vfs_utimens
.mtime
= tv
[1].tv_sec
;
36 m
.m_vfs_utimens
.ansec
= tv
[0].tv_usec
* 1000;
37 m
.m_vfs_utimens
.mnsec
= tv
[1].tv_usec
* 1000;
39 m
.m_vfs_utimens
.flags
= 0;
41 return(_syscall(VFS_PROC_NR
, VFS_UTIMENS
, &m
));