提交 d8991e86 编写于 作者: C Chengguang Xu 提交者: Miklos Szeredi

ovl: update ctime when changing fileattr

Currently we keep size, mode and times of overlay inode
as the same as upper inode, so should update ctime when
changing file attribution as well.
Signed-off-by: NChengguang Xu <cgxu519@mykernel.net>
Signed-off-by: NMiklos Szeredi <mszeredi@redhat.com>
上级 b71759ef
......@@ -573,6 +573,9 @@ int ovl_fileattr_set(struct user_namespace *mnt_userns,
BUILD_BUG_ON(OVL_PROT_I_FLAGS_MASK & ~OVL_COPY_I_FLAGS_MASK);
flags |= inode->i_flags & OVL_PROT_I_FLAGS_MASK;
inode_set_flags(inode, flags, OVL_COPY_I_FLAGS_MASK);
/* Update ctime */
ovl_copyattr(ovl_inode_real(inode), inode);
}
ovl_drop_write(dentry);
out:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册