diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2007-02-03 23:32:47 +0000 |
---|---|---|
committer | Miklos Szeredi <miklos@szeredi.hu> | 2007-02-03 23:32:47 +0000 |
commit | 3a7c00ec0c156123c47b53ec1cd7ead001fa4dfb (patch) | |
tree | d8ea21530477edcc954d35e111724c8b770c5fa1 /lib/fuse_lowlevel.c | |
parent | 47910d7b8af40ffaccc8845d10d109871b5be604 (diff) | |
download | libfuse-3a7c00ec0c156123c47b53ec1cd7ead001fa4dfb.tar.gz |
Add filesystem stacking support to high level API
Diffstat (limited to 'lib/fuse_lowlevel.c')
-rw-r--r-- | lib/fuse_lowlevel.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index 682c503..28468df 100644 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -75,11 +75,9 @@ static void convert_stat(const struct stat *stbuf, struct fuse_attr *attr) attr->atime = stbuf->st_atime; attr->mtime = stbuf->st_mtime; attr->ctime = stbuf->st_ctime; -#ifdef FUSE_STAT_HAS_NANOSEC - attr->atimensec = ST_ATIM(stbuf).tv_nsec; - attr->mtimensec = ST_MTIM(stbuf).tv_nsec; - attr->ctimensec = ST_CTIM(stbuf).tv_nsec; -#endif + attr->atimensec = ST_ATIM_NSEC(stbuf); + attr->mtimensec = ST_MTIM_NSEC(stbuf); + attr->ctimensec = ST_CTIM_NSEC(stbuf); } static void convert_attr(const struct fuse_setattr_in *attr, struct stat *stbuf) @@ -90,10 +88,8 @@ static void convert_attr(const struct fuse_setattr_in *attr, struct stat *stbuf) stbuf->st_size = attr->size; stbuf->st_atime = attr->atime; stbuf->st_mtime = attr->mtime; -#ifdef FUSE_STAT_HAS_NANOSEC - ST_ATIM(stbuf).tv_nsec = attr->atimensec; - ST_MTIM(stbuf).tv_nsec = attr->mtimensec; -#endif + ST_ATIM_NSEC_SET(stbuf, attr->atimensec); + ST_MTIM_NSEC_SET(stbuf, attr->mtimensec); } static size_t iov_length(const struct iovec *iov, size_t count) |