mirror of
https://github.com/samba-team/samba.git
synced 2024-12-24 21:34:56 +03:00
nfs4acls: Remove a few unnecessary casts
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
This commit is contained in:
parent
fafd0a0c69
commit
5caaf00e7b
@ -181,7 +181,7 @@ struct SMB4ACL_T *smb_create_smb4acl(TALLOC_CTX *mem_ctx)
|
|||||||
}
|
}
|
||||||
theacl->controlflags = SEC_DESC_SELF_RELATIVE;
|
theacl->controlflags = SEC_DESC_SELF_RELATIVE;
|
||||||
/* theacl->first, last = NULL not needed */
|
/* theacl->first, last = NULL not needed */
|
||||||
return (struct SMB4ACL_T *)theacl;
|
return theacl;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct SMB4ACE_T *smb_add_ace4(struct SMB4ACL_T *acl, SMB_ACE4PROP_T *prop)
|
struct SMB4ACE_T *smb_add_ace4(struct SMB4ACL_T *acl, SMB_ACE4PROP_T *prop)
|
||||||
@ -203,12 +203,12 @@ struct SMB4ACE_T *smb_add_ace4(struct SMB4ACL_T *acl, SMB_ACE4PROP_T *prop)
|
|||||||
acl->first = ace;
|
acl->first = ace;
|
||||||
acl->last = ace;
|
acl->last = ace;
|
||||||
} else {
|
} else {
|
||||||
acl->last->next = (void *)ace;
|
acl->last->next = ace;
|
||||||
acl->last = ace;
|
acl->last = ace;
|
||||||
}
|
}
|
||||||
acl->naces++;
|
acl->naces++;
|
||||||
|
|
||||||
return (struct SMB4ACE_T *)ace;
|
return ace;
|
||||||
}
|
}
|
||||||
|
|
||||||
SMB_ACE4PROP_T *smb_get_ace4(struct SMB4ACE_T *ace)
|
SMB_ACE4PROP_T *smb_get_ace4(struct SMB4ACE_T *ace)
|
||||||
@ -326,9 +326,7 @@ static bool smbacl4_nfs42win(TALLOC_CTX *mem_ctx,
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (aceint=acl->first;
|
for (aceint = acl->first; aceint != NULL; aceint = aceint->next) {
|
||||||
aceint!=NULL;
|
|
||||||
aceint=(struct SMB4ACE_T *)aceint->next) {
|
|
||||||
uint32_t mask;
|
uint32_t mask;
|
||||||
struct dom_sid sid;
|
struct dom_sid sid;
|
||||||
SMB_ACE4PROP_T *ace = &aceint->prop;
|
SMB_ACE4PROP_T *ace = &aceint->prop;
|
||||||
@ -586,9 +584,7 @@ static void smbacl4_dump_nfs4acl(int level, struct SMB4ACL_T *acl)
|
|||||||
|
|
||||||
DEBUG(level, ("NFS4ACL: size=%d\n", acl->naces));
|
DEBUG(level, ("NFS4ACL: size=%d\n", acl->naces));
|
||||||
|
|
||||||
for (aceint = acl->first;
|
for (aceint = acl->first; aceint != NULL; aceint = aceint->next) {
|
||||||
aceint!=NULL;
|
|
||||||
aceint=(struct SMB4ACE_T *)aceint->next) {
|
|
||||||
SMB_ACE4PROP_T *ace = &aceint->prop;
|
SMB_ACE4PROP_T *ace = &aceint->prop;
|
||||||
|
|
||||||
DEBUG(level, ("\tACE: type=%d, flags=0x%x, fflags=0x%x, "
|
DEBUG(level, ("\tACE: type=%d, flags=0x%x, fflags=0x%x, "
|
||||||
@ -611,8 +607,7 @@ static SMB_ACE4PROP_T *smbacl4_find_equal_special(
|
|||||||
{
|
{
|
||||||
struct SMB4ACE_T *aceint;
|
struct SMB4ACE_T *aceint;
|
||||||
|
|
||||||
for (aceint = acl->first; aceint != NULL;
|
for (aceint = acl->first; aceint != NULL; aceint = aceint->next) {
|
||||||
aceint=(struct SMB4ACE_T *)aceint->next) {
|
|
||||||
SMB_ACE4PROP_T *ace = &aceint->prop;
|
SMB_ACE4PROP_T *ace = &aceint->prop;
|
||||||
|
|
||||||
DEBUG(10,("ace type:0x%x flags:0x%x aceFlags:0x%x "
|
DEBUG(10,("ace type:0x%x flags:0x%x aceFlags:0x%x "
|
||||||
@ -782,8 +777,7 @@ static int smbacl4_substitute_special(
|
|||||||
{
|
{
|
||||||
struct SMB4ACE_T *aceint;
|
struct SMB4ACE_T *aceint;
|
||||||
|
|
||||||
for(aceint = acl->first; aceint!=NULL;
|
for (aceint = acl->first; aceint != NULL; aceint = aceint->next) {
|
||||||
aceint=(struct SMB4ACE_T *)aceint->next) {
|
|
||||||
SMB_ACE4PROP_T *ace = &aceint->prop;
|
SMB_ACE4PROP_T *ace = &aceint->prop;
|
||||||
|
|
||||||
DEBUG(10,("ace type: %d, iflags: %x, flags: %x, "
|
DEBUG(10,("ace type: %d, iflags: %x, flags: %x, "
|
||||||
@ -818,8 +812,7 @@ static int smbacl4_substitute_simple(
|
|||||||
{
|
{
|
||||||
struct SMB4ACE_T *aceint;
|
struct SMB4ACE_T *aceint;
|
||||||
|
|
||||||
for(aceint = acl->first; aceint!=NULL;
|
for (aceint = acl->first; aceint != NULL; aceint = aceint->next) {
|
||||||
aceint=(struct SMB4ACE_T *)aceint->next) {
|
|
||||||
SMB_ACE4PROP_T *ace = &aceint->prop;
|
SMB_ACE4PROP_T *ace = &aceint->prop;
|
||||||
|
|
||||||
DEBUG(10,("ace type: %d, iflags: %x, flags: %x, "
|
DEBUG(10,("ace type: %d, iflags: %x, flags: %x, "
|
||||||
|
Loading…
Reference in New Issue
Block a user