From 53c84862ce0de17f6d63d26cfa20008c57dc7074 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Mon, 2 Feb 2009 03:04:47 +0000 Subject: [ftpfs] 2009-02-02 Samuel Thibault * dir.c (ftpfs_refresh_node): Use st_mtim.tv_sec members instead of st_mtime. Also compare st_mtim.tv_nsec members. [libdiskfs] 2009-02-02 Samuel Thibault * file-utimes.c (diskfs_S_file_utimes): Use st_atim.tv_sec/ st_mtim.tv_sec members instead of st_atime/st_mtime. Also set st_atim.tv_nsec/st_mtim.tv_nsec members. [libftpconn] 2009-02-02 Samuel Thibault * unix.c (parse_dir_entry): Use st_mtim.tv_sec instead of st_mtime. Set st_atim.tv_nsec, st_ctim.tv_nsec and st_mtim.tv_nsec to 0. [login] 2009-02-02 Samuel Thibault * utmp.c (S_login_get_idle_time): Use st_atim.tv_sec and st_atim.tv_nsec members instead of st_atime and st_atime_usec. [tmpfs] 2009-02-02 Samuel Thibault * tmpfs.h (struct disknode): Make atime, mtime and ctime members struct timespec instead of time_t. * tmpfs.c (main): Copy st_atim/st_mtim/st_ctim members from st to diskfs_root_node->dn_stat instead of st_atime/st_mtime/st_ctime. * node.c (diskfs_node_norefs): Copy st_atime/st_mtime/st_ctime members from np->dn_stat to atime/mtime/ctime members of np->dn (diskfs_cached_lookup): Conversely. --- tmpfs/ChangeLog | 10 ++++++++++ tmpfs/node.c | 12 ++++++------ tmpfs/tmpfs.c | 6 +++--- tmpfs/tmpfs.h | 2 +- 4 files changed, 20 insertions(+), 10 deletions(-) (limited to 'tmpfs') diff --git a/tmpfs/ChangeLog b/tmpfs/ChangeLog index a5cb2989..ca44e3d2 100644 --- a/tmpfs/ChangeLog +++ b/tmpfs/ChangeLog @@ -1,3 +1,13 @@ +2009-02-02 Samuel Thibault + + * tmpfs.h (struct disknode): Make atime, mtime and ctime members + struct timespec instead of time_t. + * tmpfs.c (main): Copy st_atim/st_mtim/st_ctim members from st to + diskfs_root_node->dn_stat instead of st_atime/st_mtime/st_ctime. + * node.c (diskfs_node_norefs): Copy st_atime/st_mtime/st_ctime + members from np->dn_stat to atime/mtime/ctime members of np->dn + (diskfs_cached_lookup): Conversely. + 2005-03-20 Marcus Brinkmann * tmpfs.c (parse_opt): Use the right argument for parsing the diff --git a/tmpfs/node.c b/tmpfs/node.c index fd6bd722..55a45723 100644 --- a/tmpfs/node.c +++ b/tmpfs/node.c @@ -96,9 +96,9 @@ diskfs_node_norefs (struct node *np) np->dn->uid = np->dn_stat.st_uid; np->dn->author = np->dn_stat.st_author; np->dn->gid = np->dn_stat.st_gid; - np->dn->atime = np->dn_stat.st_atime; - np->dn->mtime = np->dn_stat.st_mtime; - np->dn->ctime = np->dn_stat.st_ctime; + np->dn->atime = np->dn_stat.st_atim; + np->dn->mtime = np->dn_stat.st_mtim; + np->dn->ctime = np->dn_stat.st_ctim; np->dn->flags = np->dn_stat.st_flags; switch (np->dn->type) @@ -200,9 +200,9 @@ diskfs_cached_lookup (ino_t inum, struct node **npp) st->st_uid = dn->uid; st->st_author = dn->author; st->st_gid = dn->gid; - st->st_atime = dn->atime; - st->st_mtime = dn->mtime; - st->st_ctime = dn->ctime; + st->st_atim = dn->atime; + st->st_mtim = dn->mtime; + st->st_ctim = dn->ctime; st->st_flags = dn->flags; st->st_rdev = 0; diff --git a/tmpfs/tmpfs.c b/tmpfs/tmpfs.c index 1539054f..cd67dd74 100644 --- a/tmpfs/tmpfs.c +++ b/tmpfs/tmpfs.c @@ -355,9 +355,9 @@ main (int argc, char **argv) diskfs_root_node->dn_stat.st_uid = st.st_uid; diskfs_root_node->dn_stat.st_author = st.st_author; diskfs_root_node->dn_stat.st_gid = st.st_gid; - diskfs_root_node->dn_stat.st_atime = st.st_atime; - diskfs_root_node->dn_stat.st_mtime = st.st_mtime; - diskfs_root_node->dn_stat.st_ctime = st.st_ctime; + diskfs_root_node->dn_stat.st_atim = st.st_atim; + diskfs_root_node->dn_stat.st_mtim = st.st_mtim; + diskfs_root_node->dn_stat.st_ctim = st.st_ctim; diskfs_root_node->dn_stat.st_flags = st.st_flags; } diskfs_root_node->dn_stat.st_mode &= ~S_ITRANS; diff --git a/tmpfs/tmpfs.h b/tmpfs/tmpfs.h index 4fb418a2..3032ce3c 100644 --- a/tmpfs/tmpfs.h +++ b/tmpfs/tmpfs.h @@ -35,7 +35,7 @@ struct disknode nlink_t nlink; uid_t uid, author; gid_t gid; - time_t atime, mtime, ctime; + struct timespec atime, mtime, ctime; unsigned int flags; char *trans; -- cgit v1.2.3