s3: VFS: posixacl: Remove posixacl_sys_acl_set_file().
authorJeremy Allison <jra@samba.org>
Wed, 9 Jun 2021 00:07:23 +0000 (17:07 -0700)
committerRalph Boehme <slow@samba.org>
Wed, 9 Jun 2021 13:14:31 +0000 (13:14 +0000)
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/modules/vfs_posixacl.c
source3/modules/vfs_posixacl.h

index 9697b12226a1b7065709e00c19df9a7909a209ab..2c2b68931a0f7a4b3b14925d472dd0628e8ea744 100644 (file)
@@ -82,42 +82,6 @@ SMB_ACL_T posixacl_sys_acl_get_fd(vfs_handle_struct *handle,
        return result;
 }
 
-int posixacl_sys_acl_set_file(vfs_handle_struct *handle,
-                             const struct smb_filename *smb_fname,
-                             SMB_ACL_TYPE_T type,
-                             SMB_ACL_T theacl)
-{
-       int res;
-       acl_type_t acl_type;
-       acl_t acl;
-
-       DEBUG(10, ("Calling acl_set_file: %s, %d\n",
-                       smb_fname->base_name,
-                       type));
-
-       switch(type) {
-       case SMB_ACL_TYPE_ACCESS:
-               acl_type = ACL_TYPE_ACCESS;
-               break;
-       case SMB_ACL_TYPE_DEFAULT:
-               acl_type = ACL_TYPE_DEFAULT;
-               break;
-       default:
-               errno = EINVAL;
-               return -1;
-       }
-
-       if ((acl = smb_acl_to_posix(theacl)) == NULL) {
-               return -1;
-       }
-       res = acl_set_file(smb_fname->base_name, acl_type, acl);
-       if (res != 0) {
-               DEBUG(10, ("acl_set_file failed: %s\n", strerror(errno)));
-       }
-       acl_free(acl);
-       return res;
-}
-
 int posixacl_sys_acl_set_fd(vfs_handle_struct *handle,
                            files_struct *fsp,
                            SMB_ACL_TYPE_T type,
index ab8b1da2eb365fc0ab08f53d3a8a17abe3edcd2e..91166ed6452eabaf785a0b90e0350b8c6c44b0be 100644 (file)
@@ -26,11 +26,6 @@ SMB_ACL_T posixacl_sys_acl_get_fd(vfs_handle_struct *handle,
                                  SMB_ACL_TYPE_T type,
                                  TALLOC_CTX *mem_ctx);
 
-int posixacl_sys_acl_set_file(vfs_handle_struct *handle,
-                             const struct smb_filename *smb_fname,
-                             SMB_ACL_TYPE_T type,
-                             SMB_ACL_T theacl);
-
 int posixacl_sys_acl_set_fd(vfs_handle_struct *handle,
                            files_struct *fsp,
                            SMB_ACL_TYPE_T type,