]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: VFS: vfs_virusfilter: Remove unlink_fn. No longer used.
authorJeremy Allison <jra@samba.org>
Wed, 18 Sep 2019 02:15:38 +0000 (19:15 -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_virusfilter.c

index 6b16193339ff16b0aecd243146444d89e9f650ff..828fd166eed881d4e343195ecae658c7360be97e 100644 (file)
@@ -1432,34 +1432,6 @@ virusfilter_vfs_close_fail:
        return close_result;
 }
 
-static int virusfilter_vfs_unlink(
-       struct vfs_handle_struct *handle,
-       const struct smb_filename *smb_fname)
-{
-       int ret = SMB_VFS_NEXT_UNLINK(handle, smb_fname);
-       struct virusfilter_config *config = NULL;
-       char *fname = NULL;
-       char *cwd_fname = handle->conn->cwd_fsp->fsp_name->base_name;
-
-       if (ret != 0 && errno != ENOENT) {
-               return ret;
-       }
-
-       SMB_VFS_HANDLE_GET_DATA(handle, config,
-                               struct virusfilter_config, return -1);
-
-       if (config->cache == NULL) {
-               return 0;
-       }
-
-       fname = smb_fname->base_name;
-
-       DBG_DEBUG("Removing cache entry (if existent): fname: %s\n", fname);
-       virusfilter_cache_remove(config->cache, cwd_fname, fname);
-
-       return 0;
-}
-
 static int virusfilter_vfs_unlinkat(struct vfs_handle_struct *handle,
                struct files_struct *dirfsp,
                const struct smb_filename *smb_fname,
@@ -1539,7 +1511,6 @@ static struct vfs_fn_pointers vfs_virusfilter_fns = {
        .disconnect_fn  = virusfilter_vfs_disconnect,
        .open_fn        = virusfilter_vfs_open,
        .close_fn       = virusfilter_vfs_close,
-       .unlink_fn      = virusfilter_vfs_unlink,
        .unlinkat_fn    = virusfilter_vfs_unlinkat,
        .renameat_fn    = virusfilter_vfs_renameat,
 };