]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
client: fix snap directory atime 33879/head
authorLuis Henriques <lhenriques@suse.com>
Wed, 11 Mar 2020 11:10:05 +0000 (11:10 +0000)
committerLuis Henriques <lhenriques@suse.de>
Thu, 18 Jun 2020 09:38:35 +0000 (10:38 +0100)
For consistency, also get the .snap directory atime from the parent
directory.  Otherwise, this timestamp will be kept at 1970-01-01.

Fixes: https://tracker.ceph.com/issues/46070
Signed-off-by: Luis Henriques <lhenriques@suse.com>
src/client/Client.cc

index 84fcf91d0d926ca5fa9a84c508daf260024cb361..91e5125ed5a9bc682530363631f026f39a83b53e 100644 (file)
@@ -10673,6 +10673,7 @@ Inode *Client::open_snapdir(Inode *diri)
     in->mtime = diri->mtime;
     in->ctime = diri->ctime;
     in->btime = diri->btime;
+    in->atime = diri->atime;
     in->size = diri->size;
     in->change_attr = diri->change_attr;