clang complains:
../../source3/smbd/posix_acls.c:2783:9: error: variable 'mask_perms' set but not used [-Werror,-Wunused-but-set-variable]
mode_t mask_perms = 0;
^
That is, the variable is initialised and updated but the value is
never used.
This potentially points to a bug in commit
f735551b9edef66b152261cf6eb2f29b7b69d65b from 2002.
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Volker Lendecke <vl@samba.org>
SMB_ACL_PERMSET_T mask_permset;
SMB_ACL_TYPE_T the_acl_type = (default_ace ? SMB_ACL_TYPE_DEFAULT : SMB_ACL_TYPE_ACCESS);
bool needs_mask = False;
- mode_t mask_perms = 0;
int sret;
/* Use the psbuf that was passed in. */
if (p_ace->type == SMB_ACL_USER || p_ace->type == SMB_ACL_GROUP) {
needs_mask = True;
- mask_perms |= p_ace->perms;
- } else if (p_ace->type == SMB_ACL_GROUP_OBJ) {
- mask_perms |= p_ace->perms;
}
/*