50dc83
From d9781ed4964d9e752fc880c8cd8afcbd2c561ebe Mon Sep 17 00:00:00 2001
50dc83
From: Jiffin Tony Thottan <jthottan@redhat.com>
50dc83
Date: Wed, 26 Jun 2019 15:58:33 +0530
50dc83
Subject: [PATCH 219/221] posix : add posix_set_ctime() in posix_ftruncate()
50dc83
50dc83
Upstream references :
50dc83
> release 6: https://review.gluster.org/#/c/glusterfs/+/22965/
50dc83
> mainline: https://review.gluster.org/#/c/glusterfs/+/22948/
50dc83
50dc83
Change-Id: I0cb5320fea71306e0283509ae47024f23874b53b
50dc83
fixes: bz#1720163
50dc83
Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
50dc83
Reviewed-on: https://code.engineering.redhat.com/gerrit/174837
50dc83
Tested-by: RHGS Build Bot <nigelb@redhat.com>
50dc83
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
50dc83
---
50dc83
 xlators/storage/posix/src/posix-inode-fd-ops.c | 2 ++
50dc83
 1 file changed, 2 insertions(+)
50dc83
50dc83
diff --git a/xlators/storage/posix/src/posix-inode-fd-ops.c b/xlators/storage/posix/src/posix-inode-fd-ops.c
50dc83
index fc847d6..c949f68 100644
50dc83
--- a/xlators/storage/posix/src/posix-inode-fd-ops.c
50dc83
+++ b/xlators/storage/posix/src/posix-inode-fd-ops.c
50dc83
@@ -5059,6 +5059,8 @@ posix_ftruncate(call_frame_t *frame, xlator_t *this, fd_t *fd, off_t offset,
50dc83
         goto out;
50dc83
     }
50dc83
 
50dc83
+    posix_set_ctime(frame, this, NULL, pfd->fd, fd->inode, &postop);
50dc83
+
50dc83
     op_ret = 0;
50dc83
 
50dc83
 out:
50dc83
-- 
50dc83
1.8.3.1
50dc83