propagating file change attr for setacl

This commit is contained in:
Olga Kornievskaia 2012-02-06 14:22:38 -05:00 committed by unknown
parent cdf31d3ee0
commit 13c3723191
3 changed files with 13 additions and 0 deletions

View file

@ -785,13 +785,21 @@ static int handle_setacl(nfs41_upcall *upcall)
nfs_error_string(status)); nfs_error_string(status));
status = nfs_to_windows_error(status, ERROR_NOT_SUPPORTED); status = nfs_to_windows_error(status, ERROR_NOT_SUPPORTED);
} }
args->ctime = info.change;
if (args->query & DACL_SECURITY_INFORMATION) if (args->query & DACL_SECURITY_INFORMATION)
free(nfs4_acl.aces); free(nfs4_acl.aces);
out: out:
return status; return status;
} }
static int marshall_setacl(unsigned char *buffer, uint32_t *length, nfs41_upcall *upcall)
{
setacl_upcall_args *args = &upcall->args.setacl;
return safe_write(&buffer, length, &args->ctime, sizeof(args->ctime));
}
const nfs41_upcall_op nfs41_op_setacl = { const nfs41_upcall_op nfs41_op_setacl = {
parse_setacl, parse_setacl,
handle_setacl, handle_setacl,
marshall_setacl
}; };

View file

@ -170,6 +170,7 @@ typedef struct __getacl_upcall_args {
typedef struct __setacl_upcall_args { typedef struct __setacl_upcall_args {
SECURITY_INFORMATION query; SECURITY_INFORMATION query;
PSECURITY_DESCRIPTOR sec_desc; PSECURITY_DESCRIPTOR sec_desc;
ULONGLONG ctime;
} setacl_upcall_args; } setacl_upcall_args;
typedef union __upcall_args { typedef union __upcall_args {

View file

@ -235,6 +235,7 @@ typedef struct _updowncall_entry {
SECURITY_INFORMATION query; SECURITY_INFORMATION query;
PVOID buf; PVOID buf;
DWORD buf_len; DWORD buf_len;
ULONGLONG ChangeTime;
} Acl; } Acl;
} u; } u;
@ -1821,6 +1822,9 @@ NTSTATUS nfs41_downcall(
case NFS41_EA_SET: case NFS41_EA_SET:
unmarshal_nfs41_setattr(cur, &cur->u.SetEa.ChangeTime, &buf); unmarshal_nfs41_setattr(cur, &cur->u.SetEa.ChangeTime, &buf);
break; break;
case NFS41_ACL_SET:
unmarshal_nfs41_setattr(cur, &cur->u.Acl.ChangeTime, &buf);
break;
} }
} }
DbgP("[downcall] About to signal waiting IO thread\n"); DbgP("[downcall] About to signal waiting IO thread\n");