s3: VFS: vfs_snapper: Remove unlink_fn. No longer used.
authorJeremy Allison <jra@samba.org>
Wed, 18 Sep 2019 02:05:27 +0000 (19:05 -0700)
committerRalph Boehme <slow@samba.org>
Thu, 26 Sep 2019 17:20:51 +0000 (17:20 +0000)
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/modules/vfs_snapper.c

index 9f3d876317df8f9a9da0816523a1d0db891b0476..d95de5d0a2574d2556803c9c1801d3e94af1eca2 100644 (file)
@@ -2219,23 +2219,6 @@ static int snapper_gmt_open(vfs_handle_struct *handle,
        return ret;
 }
 
-static int snapper_gmt_unlink(vfs_handle_struct *handle,
-                             const struct smb_filename *smb_fname)
-{
-       time_t timestamp = 0;
-
-       if (!snapper_gmt_strip_snapshot(talloc_tos(), handle,
-                                       smb_fname->base_name,
-                                       &timestamp, NULL)) {
-               return -1;
-       }
-       if (timestamp != 0) {
-               errno = EROFS;
-               return -1;
-       }
-       return SMB_VFS_NEXT_UNLINK(handle, smb_fname);
-}
-
 static int snapper_gmt_unlinkat(vfs_handle_struct *handle,
                        struct files_struct *dirfsp,
                        const struct smb_filename *smb_fname,
@@ -2918,7 +2901,6 @@ static struct vfs_fn_pointers snapper_fns = {
        .stat_fn = snapper_gmt_stat,
        .lstat_fn = snapper_gmt_lstat,
        .open_fn = snapper_gmt_open,
-       .unlink_fn = snapper_gmt_unlink,
        .unlinkat_fn = snapper_gmt_unlinkat,
        .chmod_fn = snapper_gmt_chmod,
        .chown_fn = snapper_gmt_chown,