diff options
author | Volker Lendecke <vl@samba.org> | 2014-01-30 20:12:07 +0000 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2014-02-10 10:57:04 +0100 |
commit | de7122ddc356697777cce95d22b3fab7697b30db (patch) | |
tree | 5dda9e2b4b0c4ef1b233dde565a43e12afa57bb4 /source4/ntvfs/posix | |
parent | fefc59619b58cb0c38bf7e6ac2ebcc25a5ebbd6c (diff) | |
download | samba-de7122ddc356697777cce95d22b3fab7697b30db.tar.gz samba-de7122ddc356697777cce95d22b3fab7697b30db.tar.xz samba-de7122ddc356697777cce95d22b3fab7697b30db.zip |
source4: Use wbc_sids_to_xids
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Kai Blin <kai@samba.org>
Diffstat (limited to 'source4/ntvfs/posix')
-rw-r--r-- | source4/ntvfs/posix/pvfs_acl.c | 11 | ||||
-rw-r--r-- | source4/ntvfs/posix/pvfs_acl_nfs4.c | 8 |
2 files changed, 5 insertions, 14 deletions
diff --git a/source4/ntvfs/posix/pvfs_acl.c b/source4/ntvfs/posix/pvfs_acl.c index 730ad484ce8..2070fd105c4 100644 --- a/source4/ntvfs/posix/pvfs_acl.c +++ b/source4/ntvfs/posix/pvfs_acl.c @@ -287,7 +287,6 @@ NTSTATUS pvfs_acl_set(struct pvfs_state *pvfs, uid_t new_uid = -1; gid_t new_gid = -1; struct id_map *ids; - struct composite_context *ctx; if (pvfs->acl_ops != NULL) { status = pvfs->acl_ops->acl_load(pvfs, name, fd, req, &sd); @@ -318,9 +317,8 @@ NTSTATUS pvfs_acl_set(struct pvfs_state *pvfs, } if (!dom_sid_equal(sd->owner_sid, new_sd->owner_sid)) { ids->sid = new_sd->owner_sid; - ctx = wbc_sids_to_xids_send(pvfs->wbc_ctx, ids, 1, ids); - NT_STATUS_HAVE_NO_MEMORY(ctx); - status = wbc_sids_to_xids_recv(ctx, &ids); + status = wbc_sids_to_xids(pvfs->wbc_ctx->event_ctx, + ids, 1); NT_STATUS_NOT_OK_RETURN(status); if (ids->xid.type == ID_TYPE_BOTH || @@ -337,9 +335,8 @@ NTSTATUS pvfs_acl_set(struct pvfs_state *pvfs, } if (!dom_sid_equal(sd->group_sid, new_sd->group_sid)) { ids->sid = new_sd->group_sid; - ctx = wbc_sids_to_xids_send(pvfs->wbc_ctx, ids, 1, ids); - NT_STATUS_HAVE_NO_MEMORY(ctx); - status = wbc_sids_to_xids_recv(ctx, &ids); + status = wbc_sids_to_xids(pvfs->wbc_ctx->event_ctx, + ids, 1); NT_STATUS_NOT_OK_RETURN(status); if (ids->xid.type == ID_TYPE_BOTH || diff --git a/source4/ntvfs/posix/pvfs_acl_nfs4.c b/source4/ntvfs/posix/pvfs_acl_nfs4.c index bb88cbc051e..bf4d9c27210 100644 --- a/source4/ntvfs/posix/pvfs_acl_nfs4.c +++ b/source4/ntvfs/posix/pvfs_acl_nfs4.c @@ -124,7 +124,6 @@ static NTSTATUS pvfs_acl_save_nfs4(struct pvfs_state *pvfs, struct pvfs_filename int i; TALLOC_CTX *tmp_ctx; struct id_map *ids; - struct composite_context *ctx; tmp_ctx = talloc_new(pvfs); NT_STATUS_HAVE_NO_MEMORY(tmp_ctx); @@ -159,12 +158,7 @@ static NTSTATUS pvfs_acl_save_nfs4(struct pvfs_state *pvfs, struct pvfs_filename ids[i].status = ID_UNKNOWN; } - ctx = wbc_sids_to_xids_send(pvfs->wbc_ctx,ids, acl.a_count, ids); - if (ctx == NULL) { - talloc_free(tmp_ctx); - return NT_STATUS_NO_MEMORY; - } - status = wbc_sids_to_xids_recv(ctx, &ids); + status = wbc_sids_to_xids(pvfs->wbc_ctx->event_ctx, ids, acl.a_count); if (!NT_STATUS_IS_OK(status)) { talloc_free(tmp_ctx); return status; |