From: Jeremy Allison Date: Thu, 10 Oct 2019 21:27:36 +0000 (-0700) Subject: s3: VFS: vfs_snapper: Remove chown_fn(). X-Git-Tag: talloc-2.3.1~353 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=04e70da30b2166a5cfc73484cb156c66d4e1faf5;p=thirdparty%2Fsamba.git s3: VFS: vfs_snapper: Remove chown_fn(). No longer used. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Böhme --- diff --git a/source3/modules/vfs_snapper.c b/source3/modules/vfs_snapper.c index db7ab9f7de9..9ef04d91e76 100644 --- a/source3/modules/vfs_snapper.c +++ b/source3/modules/vfs_snapper.c @@ -2261,27 +2261,6 @@ static int snapper_gmt_chmod(vfs_handle_struct *handle, return SMB_VFS_NEXT_CHMOD(handle, smb_fname, mode); } -static int snapper_gmt_chown(vfs_handle_struct *handle, - const struct smb_filename *smb_fname, - uid_t uid, - gid_t gid) -{ - time_t timestamp = 0; - - if (!snapper_gmt_strip_snapshot(talloc_tos(), - handle, - smb_fname->base_name, - ×tamp, - NULL)) { - return -1; - } - if (timestamp != 0) { - errno = EROFS; - return -1; - } - return SMB_VFS_NEXT_CHOWN(handle, smb_fname, uid, gid); -} - static int snapper_gmt_chdir(vfs_handle_struct *handle, const struct smb_filename *smb_fname) { @@ -2887,7 +2866,6 @@ static struct vfs_fn_pointers snapper_fns = { .open_fn = snapper_gmt_open, .unlinkat_fn = snapper_gmt_unlinkat, .chmod_fn = snapper_gmt_chmod, - .chown_fn = snapper_gmt_chown, .chdir_fn = snapper_gmt_chdir, .ntimes_fn = snapper_gmt_ntimes, .readlinkat_fn = snapper_gmt_readlinkat,