X-Git-Url: http://git.samba.org/?a=blobdiff_plain;f=bin.gen_ndr%2Fdefault%2Flibrpc%2Fgen_ndr%2Fndr_echo.c;h=788c4af4109aee8f5b7fa33201457a34d0d9b979;hb=d92e3967ea993cf9573aaa40fd2ef3fcfc4cb4f3;hp=51681e758977ca07de013f7c5b3cc5a429007664;hpb=ed75173f5a1cd8897ed105fc850dd049db13440d;p=metze%2Fsamba%2Fwip.git diff --git a/bin.gen_ndr/default/librpc/gen_ndr/ndr_echo.c b/bin.gen_ndr/default/librpc/gen_ndr/ndr_echo.c index 51681e758977..788c4af4109a 100644 --- a/bin.gen_ndr/default/librpc/gen_ndr/ndr_echo.c +++ b/bin.gen_ndr/default/librpc/gen_ndr/ndr_echo.c @@ -1541,11 +1541,12 @@ _PUBLIC_ void ndr_print_echo_TestDoublePointer(struct ndr_print *ndr, const char ndr->depth--; } -static enum ndr_err_code ndr_push_echo_BytePipeIn(struct ndr_push *ndr, int flags, const struct echo_BytePipeIn *r) +static enum ndr_err_code ndr_push_echo_TestBytePipeIn(struct ndr_push *ndr, int flags, const struct echo_TestBytePipeIn *r) { NDR_PUSH_CHECK_FN_FLAGS(ndr, flags); if (flags & NDR_IN) { - NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.value)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_chunks)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.chunk_size)); } if (flags & NDR_OUT) { NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->out.result)); @@ -1553,11 +1554,12 @@ static enum ndr_err_code ndr_push_echo_BytePipeIn(struct ndr_push *ndr, int flag return NDR_ERR_SUCCESS; } -static enum ndr_err_code ndr_pull_echo_BytePipeIn(struct ndr_pull *ndr, int flags, struct echo_BytePipeIn *r) +static enum ndr_err_code ndr_pull_echo_TestBytePipeIn(struct ndr_pull *ndr, int flags, struct echo_TestBytePipeIn *r) { NDR_PULL_CHECK_FN_FLAGS(ndr, flags); if (flags & NDR_IN) { - NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.value)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_chunks)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.chunk_size)); } if (flags & NDR_OUT) { NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->out.result)); @@ -1565,25 +1567,26 @@ static enum ndr_err_code ndr_pull_echo_BytePipeIn(struct ndr_pull *ndr, int flag return NDR_ERR_SUCCESS; } -_PUBLIC_ void ndr_print_echo_BytePipeIn(struct ndr_print *ndr, const char *name, int flags, const struct echo_BytePipeIn *r) +_PUBLIC_ void ndr_print_echo_TestBytePipeIn(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestBytePipeIn *r) { - ndr_print_struct(ndr, name, "echo_BytePipeIn"); + ndr_print_struct(ndr, name, "echo_TestBytePipeIn"); if (r == NULL) { ndr_print_null(ndr); return; } ndr->depth++; if (flags & NDR_SET_VALUES) { ndr->flags |= LIBNDR_PRINT_SET_VALUES; } if (flags & NDR_IN) { - ndr_print_struct(ndr, "in", "echo_BytePipeIn"); + ndr_print_struct(ndr, "in", "echo_TestBytePipeIn"); ndr->depth++; - ndr_print_uint32(ndr, "value", r->in.value); - ndr_print_ptr(ndr, "bp", r->in.bp); + ndr_print_uint32(ndr, "num_chunks", r->in.num_chunks); + ndr_print_uint32(ndr, "chunk_size", r->in.chunk_size); + ndr_print_ptr(ndr, "in_pipe", r->in.in_pipe); ndr->depth++; ndr->depth--; ndr->depth--; } if (flags & NDR_OUT) { - ndr_print_struct(ndr, "out", "echo_BytePipeIn"); + ndr_print_struct(ndr, "out", "echo_TestBytePipeIn"); ndr->depth++; ndr_print_uint32(ndr, "result", r->out.result); ndr->depth--; @@ -1591,9 +1594,158 @@ _PUBLIC_ void ndr_print_echo_BytePipeIn(struct ndr_print *ndr, const char *name, ndr->depth--; } -static const struct ndr_interface_call_pipe echo_BytePipeIn_in_pipes[] = { +static enum ndr_err_code ndr_push_echo_TestBytePipeOut(struct ndr_push *ndr, int flags, const struct echo_TestBytePipeOut *r) +{ + NDR_PUSH_CHECK_FN_FLAGS(ndr, flags); + if (flags & NDR_IN) { + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_chunks)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.chunk_size)); + } + if (flags & NDR_OUT) { + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->out.result)); + } + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_echo_TestBytePipeOut(struct ndr_pull *ndr, int flags, struct echo_TestBytePipeOut *r) +{ + NDR_PULL_CHECK_FN_FLAGS(ndr, flags); + if (flags & NDR_IN) { + ZERO_STRUCT(r->out); + + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_chunks)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.chunk_size)); + } + if (flags & NDR_OUT) { + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->out.result)); + } + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_echo_TestBytePipeOut(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestBytePipeOut *r) +{ + ndr_print_struct(ndr, name, "echo_TestBytePipeOut"); + if (r == NULL) { ndr_print_null(ndr); return; } + ndr->depth++; + if (flags & NDR_SET_VALUES) { + ndr->flags |= LIBNDR_PRINT_SET_VALUES; + } + if (flags & NDR_IN) { + ndr_print_struct(ndr, "in", "echo_TestBytePipeOut"); + ndr->depth++; + ndr_print_uint32(ndr, "num_chunks", r->in.num_chunks); + ndr_print_uint32(ndr, "chunk_size", r->in.chunk_size); + ndr->depth--; + } + if (flags & NDR_OUT) { + ndr_print_struct(ndr, "out", "echo_TestBytePipeOut"); + ndr->depth++; + ndr_print_ptr(ndr, "out_pipe", r->out.out_pipe); + ndr->depth++; + ndr->depth--; + ndr_print_uint32(ndr, "result", r->out.result); + ndr->depth--; + } + ndr->depth--; +} + +static enum ndr_err_code ndr_push_echo_TestBytePipeInOut(struct ndr_push *ndr, int flags, const struct echo_TestBytePipeInOut *r) +{ + NDR_PUSH_CHECK_FN_FLAGS(ndr, flags); + if (flags & NDR_IN) { + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_chunks)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.chunk_size)); + } + if (flags & NDR_OUT) { + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->out.result)); + } + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_echo_TestBytePipeInOut(struct ndr_pull *ndr, int flags, struct echo_TestBytePipeInOut *r) +{ + NDR_PULL_CHECK_FN_FLAGS(ndr, flags); + if (flags & NDR_IN) { + ZERO_STRUCT(r->out); + + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_chunks)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.chunk_size)); + } + if (flags & NDR_OUT) { + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->out.result)); + } + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_echo_TestBytePipeInOut(struct ndr_print *ndr, const char *name, int flags, const struct echo_TestBytePipeInOut *r) +{ + ndr_print_struct(ndr, name, "echo_TestBytePipeInOut"); + if (r == NULL) { ndr_print_null(ndr); return; } + ndr->depth++; + if (flags & NDR_SET_VALUES) { + ndr->flags |= LIBNDR_PRINT_SET_VALUES; + } + if (flags & NDR_IN) { + ndr_print_struct(ndr, "in", "echo_TestBytePipeInOut"); + ndr->depth++; + ndr_print_uint32(ndr, "num_chunks", r->in.num_chunks); + ndr_print_uint32(ndr, "chunk_size", r->in.chunk_size); + ndr_print_ptr(ndr, "out_pipe", r->in.out_pipe); + ndr->depth++; + ndr->depth--; + ndr->depth--; + } + if (flags & NDR_OUT) { + ndr_print_struct(ndr, "out", "echo_TestBytePipeInOut"); + ndr->depth++; + ndr_print_ptr(ndr, "out_pipe", r->out.out_pipe); + ndr->depth++; + ndr->depth--; + ndr_print_uint32(ndr, "result", r->out.result); + ndr->depth--; + } + ndr->depth--; +} + +static const struct ndr_interface_call_pipe echo_TestBytePipeIn_in_pipes[] = { + { + "in.in_pipe", + "echo_BytePipe_chunk", + sizeof(struct echo_BytePipe_chunk), + (ndr_push_flags_fn_t) ndr_push_echo_BytePipe_chunk, + (ndr_pull_flags_fn_t) ndr_pull_echo_BytePipe_chunk, + (ndr_print_fn_t) ndr_print_echo_BytePipe_chunk, + }, + { NULL, NULL, 0, NULL, NULL, NULL } +}; + +static const struct ndr_interface_call_pipe echo_TestBytePipeOut_out_pipes[] = { + { + "out.out_pipe", + "echo_BytePipe_chunk", + sizeof(struct echo_BytePipe_chunk), + (ndr_push_flags_fn_t) ndr_push_echo_BytePipe_chunk, + (ndr_pull_flags_fn_t) ndr_pull_echo_BytePipe_chunk, + (ndr_print_fn_t) ndr_print_echo_BytePipe_chunk, + }, + { NULL, NULL, 0, NULL, NULL, NULL } +}; + +static const struct ndr_interface_call_pipe echo_TestBytePipeInOut_in_pipes[] = { { - "in.bp", + "in.out_pipe", + "echo_BytePipe_chunk", + sizeof(struct echo_BytePipe_chunk), + (ndr_push_flags_fn_t) ndr_push_echo_BytePipe_chunk, + (ndr_pull_flags_fn_t) ndr_pull_echo_BytePipe_chunk, + (ndr_print_fn_t) ndr_print_echo_BytePipe_chunk, + }, + { NULL, NULL, 0, NULL, NULL, NULL } +}; + +static const struct ndr_interface_call_pipe echo_TestBytePipeInOut_out_pipes[] = { + { + "out.out_pipe", "echo_BytePipe_chunk", sizeof(struct echo_BytePipe_chunk), (ndr_push_flags_fn_t) ndr_push_echo_BytePipe_chunk, @@ -1695,14 +1847,32 @@ static const struct ndr_interface_call rpcecho_calls[] = { { 0, NULL }, }, { - "echo_BytePipeIn", - sizeof(struct echo_BytePipeIn), - (ndr_push_flags_fn_t) ndr_push_echo_BytePipeIn, - (ndr_pull_flags_fn_t) ndr_pull_echo_BytePipeIn, - (ndr_print_function_t) ndr_print_echo_BytePipeIn, - { 1, echo_BytePipeIn_in_pipes }, + "echo_TestBytePipeIn", + sizeof(struct echo_TestBytePipeIn), + (ndr_push_flags_fn_t) ndr_push_echo_TestBytePipeIn, + (ndr_pull_flags_fn_t) ndr_pull_echo_TestBytePipeIn, + (ndr_print_function_t) ndr_print_echo_TestBytePipeIn, + { 1, echo_TestBytePipeIn_in_pipes }, { 0, NULL }, }, + { + "echo_TestBytePipeOut", + sizeof(struct echo_TestBytePipeOut), + (ndr_push_flags_fn_t) ndr_push_echo_TestBytePipeOut, + (ndr_pull_flags_fn_t) ndr_pull_echo_TestBytePipeOut, + (ndr_print_function_t) ndr_print_echo_TestBytePipeOut, + { 0, NULL }, + { 1, echo_TestBytePipeOut_out_pipes }, + }, + { + "echo_TestBytePipeInOut", + sizeof(struct echo_TestBytePipeInOut), + (ndr_push_flags_fn_t) ndr_push_echo_TestBytePipeInOut, + (ndr_pull_flags_fn_t) ndr_pull_echo_TestBytePipeInOut, + (ndr_print_function_t) ndr_print_echo_TestBytePipeInOut, + { 1, echo_TestBytePipeInOut_in_pipes }, + { 1, echo_TestBytePipeInOut_out_pipes }, + }, { NULL, 0, NULL, NULL, NULL } }; @@ -1734,7 +1904,7 @@ const struct ndr_interface_table ndr_table_rpcecho = { NDR_RPCECHO_VERSION }, .helpstring = NDR_RPCECHO_HELPSTRING, - .num_calls = 11, + .num_calls = 13, .calls = rpcecho_calls, .endpoints = &rpcecho_endpoints, .authservices = &rpcecho_authservices