mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-25 11:47:43 +03:00
Remove bcopy(), bzero(), bcmp()
bcopy() has a confusing argument order and is actually a move, not a copy; they're all deprecated since POSIX.1-2001 and removed in -2008, and we shim them out to mem*() on Linux anyway Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Closes #12996
This commit is contained in:
@@ -40,7 +40,7 @@ struct zfs2bsd {
|
||||
int zb_bsd;
|
||||
};
|
||||
|
||||
struct zfs2bsd perms[] = {{ACE_READ_DATA, ACL_READ_DATA},
|
||||
static const struct zfs2bsd perms[] = {{ACE_READ_DATA, ACL_READ_DATA},
|
||||
{ACE_WRITE_DATA, ACL_WRITE_DATA},
|
||||
{ACE_EXECUTE, ACL_EXECUTE},
|
||||
{ACE_APPEND_DATA, ACL_APPEND_DATA},
|
||||
@@ -56,7 +56,7 @@ struct zfs2bsd perms[] = {{ACE_READ_DATA, ACL_READ_DATA},
|
||||
{ACE_SYNCHRONIZE, ACL_SYNCHRONIZE},
|
||||
{0, 0}};
|
||||
|
||||
struct zfs2bsd flags[] = {{ACE_FILE_INHERIT_ACE,
|
||||
static const struct zfs2bsd flags[] = {{ACE_FILE_INHERIT_ACE,
|
||||
ACL_ENTRY_FILE_INHERIT},
|
||||
{ACE_DIRECTORY_INHERIT_ACE,
|
||||
ACL_ENTRY_DIRECTORY_INHERIT},
|
||||
@@ -122,7 +122,7 @@ acl_from_aces(struct acl *aclp, const ace_t *aces, int nentries)
|
||||
return (EINVAL);
|
||||
}
|
||||
|
||||
bzero(aclp, sizeof (*aclp));
|
||||
memset(aclp, 0, sizeof (*aclp));
|
||||
aclp->acl_maxcnt = ACL_MAX_ENTRIES;
|
||||
aclp->acl_cnt = nentries;
|
||||
|
||||
@@ -177,7 +177,7 @@ aces_from_acl(ace_t *aces, int *nentries, const struct acl *aclp)
|
||||
const struct acl_entry *entry;
|
||||
ace_t *ace;
|
||||
|
||||
bzero(aces, sizeof (*aces) * aclp->acl_cnt);
|
||||
memset(aces, 0, sizeof (*aces) * aclp->acl_cnt);
|
||||
|
||||
*nentries = aclp->acl_cnt;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user