summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/dht/src/dht-helper.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/cluster/dht/src/dht-helper.c')
-rw-r--r--xlators/cluster/dht/src/dht-helper.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/xlators/cluster/dht/src/dht-helper.c b/xlators/cluster/dht/src/dht-helper.c
index 10fc1ccdae4..0ef88a59b62 100644
--- a/xlators/cluster/dht/src/dht-helper.c
+++ b/xlators/cluster/dht/src/dht-helper.c
@@ -311,13 +311,14 @@ dht_stat_merge (xlator_t *this, struct stat *to,
to->st_mode = from->st_mode;
to->st_nlink = from->st_nlink;
- to->st_uid = from->st_uid;
- to->st_gid = from->st_gid;
to->st_rdev = from->st_rdev;
to->st_size += from->st_size;
to->st_blksize = from->st_blksize;
to->st_blocks += from->st_blocks;
+ set_if_greater (to->st_uid, from->st_uid);
+ set_if_greater (to->st_gid, from->st_gid);
+
set_if_greater (to->st_atime, from->st_atime);
set_if_greater (to->st_mtime, from->st_mtime);
set_if_greater (to->st_ctime, from->st_ctime);