diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2005-02-09 21:10:23 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:09:36 -0500 |
commit | 632acd9bc7704ac3d326354808c3d12f4f0a9f8f (patch) | |
tree | b801c24612751b65c3af360e6842396f0e96d85b /source4/ntvfs/ipc | |
parent | 73d317e0dae5d9dd30300da9dd19abaaef5db03f (diff) | |
download | samba-632acd9bc7704ac3d326354808c3d12f4f0a9f8f.tar.gz samba-632acd9bc7704ac3d326354808c3d12f4f0a9f8f.tar.bz2 samba-632acd9bc7704ac3d326354808c3d12f4f0a9f8f.zip |
r5286: Some first steps in making the pidl code somewhat more generic for the
various data types:
Add ndr_flags argument to all ndr push/pull scalar functions
(This used to be commit ab490c0c882bb13de190546c50a0631ecb8255ad)
Diffstat (limited to 'source4/ntvfs/ipc')
-rw-r--r-- | source4/ntvfs/ipc/ipc_rap.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/source4/ntvfs/ipc/ipc_rap.c b/source4/ntvfs/ipc/ipc_rap.c index a61dbcb852..7ee7d26e35 100644 --- a/source4/ntvfs/ipc/ipc_rap.c +++ b/source4/ntvfs/ipc/ipc_rap.c @@ -109,7 +109,7 @@ static NTSTATUS rap_srv_pull_word(struct rap_call *call, uint16 *result) if (*call->paramdesc++ != 'W') return NT_STATUS_INVALID_PARAMETER; - return ndr_pull_uint16(call->ndr_pull_param, result); + return ndr_pull_uint16(call->ndr_pull_param, NDR_SCALARS, result); } static NTSTATUS rap_srv_pull_dword(struct rap_call *call, uint32 *result) @@ -117,7 +117,7 @@ static NTSTATUS rap_srv_pull_dword(struct rap_call *call, uint32 *result) if (*call->paramdesc++ != 'D') return NT_STATUS_INVALID_PARAMETER; - return ndr_pull_uint32(call->ndr_pull_param, result); + return ndr_pull_uint32(call->ndr_pull_param, NDR_SCALARS, result); } static NTSTATUS rap_srv_pull_string(struct rap_call *call, const char **result) @@ -142,7 +142,7 @@ static NTSTATUS rap_srv_pull_bufsize(struct rap_call *call, uint16 *bufsize) if ( (*call->paramdesc++ != 'r') || (*call->paramdesc++ != 'L') ) return NT_STATUS_INVALID_PARAMETER; - result = ndr_pull_uint16(call->ndr_pull_param, bufsize); + result = ndr_pull_uint16(call->ndr_pull_param, NDR_SCALARS, bufsize); if (!NT_STATUS_IS_OK(result)) return result; @@ -176,8 +176,8 @@ static NTSTATUS rap_push_string(struct ndr_push *data_push, heap->offset -= space; - NDR_CHECK(ndr_push_uint16(data_push, heap->offset)); - NDR_CHECK(ndr_push_uint16(data_push, 0)); + NDR_CHECK(ndr_push_uint16(data_push, NDR_SCALARS, heap->offset)); + NDR_CHECK(ndr_push_uint16(data_push, NDR_SCALARS, 0)); heap->strings = talloc_realloc(heap->mem_ctx, heap->strings, @@ -249,9 +249,9 @@ static NTSTATUS _rap_netshareenum(struct smbsrv_request *req, (const uint8_t *)r.out.info[i].info1.name, sizeof(r.out.info[i].info1.name))); NDR_OK(ndr_push_uint8(call->ndr_push_data, - r.out.info[i].info1.pad)); + NDR_SCALARS, r.out.info[i].info1.pad)); NDR_OK(ndr_push_uint16(call->ndr_push_data, - r.out.info[i].info1.type)); + NDR_SCALARS, r.out.info[i].info1.type)); NDR_OK(rap_push_string(call->ndr_push_data, call->heap, @@ -272,8 +272,8 @@ static NTSTATUS _rap_netshareenum(struct smbsrv_request *req, call->status = r.out.status; - NDR_CHECK(ndr_push_uint16(call->ndr_push_param, r.out.count)); - NDR_CHECK(ndr_push_uint16(call->ndr_push_param, r.out.available)); + NDR_CHECK(ndr_push_uint16(call->ndr_push_param, NDR_SCALARS, r.out.count)); + NDR_CHECK(ndr_push_uint16(call->ndr_push_param, NDR_SCALARS, r.out.available)); result = NT_STATUS_OK; @@ -332,11 +332,11 @@ static NTSTATUS _rap_netserverenum2(struct smbsrv_request *req, (const uint8_t *)r.out.info[i].info1.name, sizeof(r.out.info[i].info1.name))); NDR_OK(ndr_push_uint8(call->ndr_push_data, - r.out.info[i].info1.version_major)); + NDR_SCALARS, r.out.info[i].info1.version_major)); NDR_OK(ndr_push_uint8(call->ndr_push_data, - r.out.info[i].info1.version_minor)); + NDR_SCALARS, r.out.info[i].info1.version_minor)); NDR_OK(ndr_push_uint32(call->ndr_push_data, - r.out.info[i].info1.servertype)); + NDR_SCALARS, r.out.info[i].info1.servertype)); NDR_OK(rap_push_string(call->ndr_push_data, call->heap, @@ -357,8 +357,8 @@ static NTSTATUS _rap_netserverenum2(struct smbsrv_request *req, call->status = r.out.status; - NDR_CHECK(ndr_push_uint16(call->ndr_push_param, r.out.count)); - NDR_CHECK(ndr_push_uint16(call->ndr_push_param, r.out.available)); + NDR_CHECK(ndr_push_uint16(call->ndr_push_param, NDR_SCALARS, r.out.count)); + NDR_CHECK(ndr_push_uint16(call->ndr_push_param, NDR_SCALARS, r.out.available)); result = NT_STATUS_OK; @@ -399,7 +399,7 @@ NTSTATUS ipc_rap_call(struct smbsrv_request *req, struct smb_trans2 *trans) if (call == NULL) return NT_STATUS_NO_MEMORY; - NDR_CHECK(ndr_pull_uint16(call->ndr_pull_param, &call->callno)); + NDR_CHECK(ndr_pull_uint16(call->ndr_pull_param, NDR_SCALARS, &call->callno)); NDR_CHECK(ndr_pull_string(call->ndr_pull_param, NDR_SCALARS, &call->paramdesc)); NDR_CHECK(ndr_pull_string(call->ndr_pull_param, NDR_SCALARS, @@ -440,9 +440,9 @@ NTSTATUS ipc_rap_call(struct smbsrv_request *req, struct smb_trans2 *trans) final_param->flags = RAPNDR_FLAGS; final_data->flags = RAPNDR_FLAGS; - NDR_CHECK(ndr_push_uint16(final_param, call->status)); + NDR_CHECK(ndr_push_uint16(final_param, NDR_SCALARS, call->status)); NDR_CHECK(ndr_push_uint16(final_param, - call->heap->offset - result_data.length)); + NDR_SCALARS, call->heap->offset - result_data.length)); NDR_CHECK(ndr_push_bytes(final_param, result_param.data, result_param.length)); |