s3: re-run make samba3-idl.
authorGünther Deschner <gd@samba.org>
Thu, 8 Apr 2010 22:11:00 +0000 (00:11 +0200)
committerGünther Deschner <gd@samba.org>
Thu, 8 Apr 2010 22:27:58 +0000 (00:27 +0200)
Guenther

librpc/gen_ndr/cli_winreg.c
librpc/gen_ndr/cli_winreg.h
librpc/gen_ndr/ndr_winreg.c
librpc/gen_ndr/ndr_winreg.h
librpc/gen_ndr/srv_winreg.c
librpc/gen_ndr/srv_winreg.h
librpc/gen_ndr/winreg.h

index 8ca72a90ca1ef98180cac6621cab58e00185aa68..57e78a7cd27677502eab63da9aee9aacdeacb90b 100644 (file)
@@ -5490,3 +5490,153 @@ NTSTATUS rpccli_winreg_QueryMultipleValues2(struct rpc_pipe_client *cli,
        return werror_to_ntstatus(r.out.result);
 }
 
+struct rpccli_winreg_DeleteKeyEx_state {
+       struct winreg_DeleteKeyEx orig;
+       struct winreg_DeleteKeyEx tmp;
+       TALLOC_CTX *out_mem_ctx;
+       NTSTATUS (*dispatch_recv)(struct tevent_req *req, TALLOC_CTX *mem_ctx);
+};
+
+static void rpccli_winreg_DeleteKeyEx_done(struct tevent_req *subreq);
+
+struct tevent_req *rpccli_winreg_DeleteKeyEx_send(TALLOC_CTX *mem_ctx,
+                                                 struct tevent_context *ev,
+                                                 struct rpc_pipe_client *cli,
+                                                 struct policy_handle *_handle /* [in] [ref] */,
+                                                 struct winreg_String *_key /* [in] [ref] */,
+                                                 uint32_t _access_mask /* [in]  */,
+                                                 uint32_t _reserved /* [in]  */)
+{
+       struct tevent_req *req;
+       struct rpccli_winreg_DeleteKeyEx_state *state;
+       struct tevent_req *subreq;
+
+       req = tevent_req_create(mem_ctx, &state,
+                               struct rpccli_winreg_DeleteKeyEx_state);
+       if (req == NULL) {
+               return NULL;
+       }
+       state->out_mem_ctx = NULL;
+       state->dispatch_recv = cli->dispatch_recv;
+
+       /* In parameters */
+       state->orig.in.handle = _handle;
+       state->orig.in.key = _key;
+       state->orig.in.access_mask = _access_mask;
+       state->orig.in.reserved = _reserved;
+
+       /* Out parameters */
+
+       /* Result */
+       ZERO_STRUCT(state->orig.out.result);
+
+       /* make a temporary copy, that we pass to the dispatch function */
+       state->tmp = state->orig;
+
+       subreq = cli->dispatch_send(state, ev, cli,
+                                   &ndr_table_winreg,
+                                   NDR_WINREG_DELETEKEYEX,
+                                   &state->tmp);
+       if (tevent_req_nomem(subreq, req)) {
+               return tevent_req_post(req, ev);
+       }
+       tevent_req_set_callback(subreq, rpccli_winreg_DeleteKeyEx_done, req);
+       return req;
+}
+
+static void rpccli_winreg_DeleteKeyEx_done(struct tevent_req *subreq)
+{
+       struct tevent_req *req = tevent_req_callback_data(
+               subreq, struct tevent_req);
+       struct rpccli_winreg_DeleteKeyEx_state *state = tevent_req_data(
+               req, struct rpccli_winreg_DeleteKeyEx_state);
+       NTSTATUS status;
+       TALLOC_CTX *mem_ctx;
+
+       if (state->out_mem_ctx) {
+               mem_ctx = state->out_mem_ctx;
+       } else {
+               mem_ctx = state;
+       }
+
+       status = state->dispatch_recv(subreq, mem_ctx);
+       TALLOC_FREE(subreq);
+       if (!NT_STATUS_IS_OK(status)) {
+               tevent_req_nterror(req, status);
+               return;
+       }
+
+       /* Copy out parameters */
+
+       /* Copy result */
+       state->orig.out.result = state->tmp.out.result;
+
+       /* Reset temporary structure */
+       ZERO_STRUCT(state->tmp);
+
+       tevent_req_done(req);
+}
+
+NTSTATUS rpccli_winreg_DeleteKeyEx_recv(struct tevent_req *req,
+                                       TALLOC_CTX *mem_ctx,
+                                       WERROR *result)
+{
+       struct rpccli_winreg_DeleteKeyEx_state *state = tevent_req_data(
+               req, struct rpccli_winreg_DeleteKeyEx_state);
+       NTSTATUS status;
+
+       if (tevent_req_is_nterror(req, &status)) {
+               tevent_req_received(req);
+               return status;
+       }
+
+       /* Steal possbile out parameters to the callers context */
+       talloc_steal(mem_ctx, state->out_mem_ctx);
+
+       /* Return result */
+       *result = state->orig.out.result;
+
+       tevent_req_received(req);
+       return NT_STATUS_OK;
+}
+
+NTSTATUS rpccli_winreg_DeleteKeyEx(struct rpc_pipe_client *cli,
+                                  TALLOC_CTX *mem_ctx,
+                                  struct policy_handle *handle /* [in] [ref] */,
+                                  struct winreg_String *key /* [in] [ref] */,
+                                  uint32_t access_mask /* [in]  */,
+                                  uint32_t reserved /* [in]  */,
+                                  WERROR *werror)
+{
+       struct winreg_DeleteKeyEx r;
+       NTSTATUS status;
+
+       /* In parameters */
+       r.in.handle = handle;
+       r.in.key = key;
+       r.in.access_mask = access_mask;
+       r.in.reserved = reserved;
+
+       status = cli->dispatch(cli,
+                               mem_ctx,
+                               &ndr_table_winreg,
+                               NDR_WINREG_DELETEKEYEX,
+                               &r);
+
+       if (!NT_STATUS_IS_OK(status)) {
+               return status;
+       }
+
+       if (NT_STATUS_IS_ERR(status)) {
+               return status;
+       }
+
+       /* Return variables */
+
+       /* Return result */
+       if (werror) {
+               *werror = r.out.result;
+       }
+
+       return werror_to_ntstatus(r.out.result);
+}
index 7bbc33cffde62dba493a18cbafede6bbeb3dd8ce..670958e70c5a8629ad7bc25f6144889a8b504504 100644 (file)
@@ -576,4 +576,21 @@ NTSTATUS rpccli_winreg_QueryMultipleValues2_recv(struct tevent_req *req,
 NTSTATUS rpccli_winreg_QueryMultipleValues2(struct rpc_pipe_client *cli,
                                            TALLOC_CTX *mem_ctx,
                                            WERROR *werror);
+struct tevent_req *rpccli_winreg_DeleteKeyEx_send(TALLOC_CTX *mem_ctx,
+                                                 struct tevent_context *ev,
+                                                 struct rpc_pipe_client *cli,
+                                                 struct policy_handle *_handle /* [in] [ref] */,
+                                                 struct winreg_String *_key /* [in] [ref] */,
+                                                 uint32_t _access_mask /* [in]  */,
+                                                 uint32_t _reserved /* [in]  */);
+NTSTATUS rpccli_winreg_DeleteKeyEx_recv(struct tevent_req *req,
+                                       TALLOC_CTX *mem_ctx,
+                                       WERROR *result);
+NTSTATUS rpccli_winreg_DeleteKeyEx(struct rpc_pipe_client *cli,
+                                  TALLOC_CTX *mem_ctx,
+                                  struct policy_handle *handle /* [in] [ref] */,
+                                  struct winreg_String *key /* [in] [ref] */,
+                                  uint32_t access_mask /* [in]  */,
+                                  uint32_t reserved /* [in]  */,
+                                  WERROR *werror);
 #endif /* __CLI_WINREG__ */
index 7088819dd041b732dd95fe7c146820e315108c6b..fcb65d42f9c44bf23ac8bff6fed855116e088c8b 100644 (file)
@@ -4407,6 +4407,85 @@ _PUBLIC_ void ndr_print_winreg_QueryMultipleValues2(struct ndr_print *ndr, const
        ndr->depth--;
 }
 
+static enum ndr_err_code ndr_push_winreg_DeleteKeyEx(struct ndr_push *ndr, int flags, const struct winreg_DeleteKeyEx *r)
+{
+       if (flags & NDR_IN) {
+               if (r->in.handle == NULL) {
+                       return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+               }
+               NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
+               if (r->in.key == NULL) {
+                       return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
+               }
+               NDR_CHECK(ndr_push_winreg_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.key));
+               NDR_CHECK(ndr_push_winreg_AccessMask(ndr, NDR_SCALARS, r->in.access_mask));
+               NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.reserved));
+       }
+       if (flags & NDR_OUT) {
+               NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
+       }
+       return NDR_ERR_SUCCESS;
+}
+
+static enum ndr_err_code ndr_pull_winreg_DeleteKeyEx(struct ndr_pull *ndr, int flags, struct winreg_DeleteKeyEx *r)
+{
+       TALLOC_CTX *_mem_save_handle_0;
+       TALLOC_CTX *_mem_save_key_0;
+       if (flags & NDR_IN) {
+               if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+                       NDR_PULL_ALLOC(ndr, r->in.handle);
+               }
+               _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
+               NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
+               NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
+               NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
+               if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
+                       NDR_PULL_ALLOC(ndr, r->in.key);
+               }
+               _mem_save_key_0 = NDR_PULL_GET_MEM_CTX(ndr);
+               NDR_PULL_SET_MEM_CTX(ndr, r->in.key, LIBNDR_FLAG_REF_ALLOC);
+               NDR_CHECK(ndr_pull_winreg_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.key));
+               NDR_PULL_SET_MEM_CTX(ndr, _mem_save_key_0, LIBNDR_FLAG_REF_ALLOC);
+               NDR_CHECK(ndr_pull_winreg_AccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
+               NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.reserved));
+       }
+       if (flags & NDR_OUT) {
+               NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
+       }
+       return NDR_ERR_SUCCESS;
+}
+
+_PUBLIC_ void ndr_print_winreg_DeleteKeyEx(struct ndr_print *ndr, const char *name, int flags, const struct winreg_DeleteKeyEx *r)
+{
+       ndr_print_struct(ndr, name, "winreg_DeleteKeyEx");
+       ndr->depth++;
+       if (flags & NDR_SET_VALUES) {
+               ndr->flags |= LIBNDR_PRINT_SET_VALUES;
+       }
+       if (flags & NDR_IN) {
+               ndr_print_struct(ndr, "in", "winreg_DeleteKeyEx");
+               ndr->depth++;
+               ndr_print_ptr(ndr, "handle", r->in.handle);
+               ndr->depth++;
+               ndr_print_policy_handle(ndr, "handle", r->in.handle);
+               ndr->depth--;
+               ndr_print_ptr(ndr, "key", r->in.key);
+               ndr->depth++;
+               ndr_print_winreg_String(ndr, "key", r->in.key);
+               ndr->depth--;
+               ndr_print_winreg_AccessMask(ndr, "access_mask", r->in.access_mask);
+               ndr_print_uint32(ndr, "reserved", r->in.reserved);
+               ndr->depth--;
+       }
+       if (flags & NDR_OUT) {
+               ndr_print_struct(ndr, "out", "winreg_DeleteKeyEx");
+               ndr->depth++;
+               ndr_print_WERROR(ndr, "result", r->out.result);
+               ndr->depth--;
+       }
+       ndr->depth--;
+}
+
 static const struct ndr_interface_call winreg_calls[] = {
        {
                "winreg_OpenHKCR",
@@ -4688,6 +4767,14 @@ static const struct ndr_interface_call winreg_calls[] = {
                (ndr_print_function_t) ndr_print_winreg_QueryMultipleValues2,
                false,
        },
+       {
+               "winreg_DeleteKeyEx",
+               sizeof(struct winreg_DeleteKeyEx),
+               (ndr_push_flags_fn_t) ndr_push_winreg_DeleteKeyEx,
+               (ndr_pull_flags_fn_t) ndr_pull_winreg_DeleteKeyEx,
+               (ndr_print_function_t) ndr_print_winreg_DeleteKeyEx,
+               false,
+       },
        { NULL, 0, NULL, NULL, NULL, false }
 };
 
@@ -4719,7 +4806,7 @@ const struct ndr_interface_table ndr_table_winreg = {
                NDR_WINREG_VERSION
        },
        .helpstring     = NDR_WINREG_HELPSTRING,
-       .num_calls      = 35,
+       .num_calls      = 36,
        .calls          = winreg_calls,
        .endpoints      = &winreg_endpoints,
        .authservices   = &winreg_authservices
index 8bee4dad358426198cbcd71da991185918676252..39f10e2ee6c9d09b0d96c11b3804c79da402fb6a 100644 (file)
@@ -81,7 +81,9 @@ extern const struct ndr_interface_table ndr_table_winreg;
 
 #define NDR_WINREG_QUERYMULTIPLEVALUES2 (0x22)
 
-#define NDR_WINREG_CALL_COUNT (35)
+#define NDR_WINREG_DELETEKEYEX (0x23)
+
+#define NDR_WINREG_CALL_COUNT (36)
 void ndr_print_winreg_AccessMask(struct ndr_print *ndr, const char *name, uint32_t r);
 enum ndr_err_code ndr_push_winreg_String(struct ndr_push *ndr, int ndr_flags, const struct winreg_String *r);
 enum ndr_err_code ndr_pull_winreg_String(struct ndr_pull *ndr, int ndr_flags, struct winreg_String *r);
@@ -160,4 +162,5 @@ void ndr_print_winreg_SaveKeyEx(struct ndr_print *ndr, const char *name, int fla
 void ndr_print_winreg_OpenHKPT(struct ndr_print *ndr, const char *name, int flags, const struct winreg_OpenHKPT *r);
 void ndr_print_winreg_OpenHKPN(struct ndr_print *ndr, const char *name, int flags, const struct winreg_OpenHKPN *r);
 void ndr_print_winreg_QueryMultipleValues2(struct ndr_print *ndr, const char *name, int flags, const struct winreg_QueryMultipleValues2 *r);
+void ndr_print_winreg_DeleteKeyEx(struct ndr_print *ndr, const char *name, int flags, const struct winreg_DeleteKeyEx *r);
 #endif /* _HEADER_NDR_winreg */
index d0873f8d62b9145a2fa59c34499dc4552e239054..b5b4adcd88772bd38ed21a88b07d1b165dd9b07b 100644 (file)
@@ -2719,6 +2719,79 @@ static bool api_winreg_QueryMultipleValues2(pipes_struct *p)
        return true;
 }
 
+static bool api_winreg_DeleteKeyEx(pipes_struct *p)
+{
+       const struct ndr_interface_call *call;
+       struct ndr_pull *pull;
+       struct ndr_push *push;
+       enum ndr_err_code ndr_err;
+       DATA_BLOB blob;
+       struct winreg_DeleteKeyEx *r;
+
+       call = &ndr_table_winreg.calls[NDR_WINREG_DELETEKEYEX];
+
+       r = talloc(talloc_tos(), struct winreg_DeleteKeyEx);
+       if (r == NULL) {
+               return false;
+       }
+
+       if (!prs_data_blob(&p->in_data.data, &blob, r)) {
+               talloc_free(r);
+               return false;
+       }
+
+       pull = ndr_pull_init_blob(&blob, r, NULL);
+       if (pull == NULL) {
+               talloc_free(r);
+               return false;
+       }
+
+       pull->flags |= LIBNDR_FLAG_REF_ALLOC;
+       ndr_err = call->ndr_pull(pull, NDR_IN, r);
+       if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+               talloc_free(r);
+               return false;
+       }
+
+       if (DEBUGLEVEL >= 10) {
+               NDR_PRINT_IN_DEBUG(winreg_DeleteKeyEx, r);
+       }
+
+       r->out.result = _winreg_DeleteKeyEx(p, r);
+
+       if (p->rng_fault_state) {
+               talloc_free(r);
+               /* Return true here, srv_pipe_hnd.c will take care */
+               return true;
+       }
+
+       if (DEBUGLEVEL >= 10) {
+               NDR_PRINT_OUT_DEBUG(winreg_DeleteKeyEx, r);
+       }
+
+       push = ndr_push_init_ctx(r, NULL);
+       if (push == NULL) {
+               talloc_free(r);
+               return false;
+       }
+
+       ndr_err = call->ndr_push(push, NDR_OUT, r);
+       if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
+               talloc_free(r);
+               return false;
+       }
+
+       blob = ndr_push_blob(push);
+       if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
+               talloc_free(r);
+               return false;
+       }
+
+       talloc_free(r);
+
+       return true;
+}
+
 
 /* Tables */
 static struct api_struct api_winreg_cmds[] = 
@@ -2758,6 +2831,7 @@ static struct api_struct api_winreg_cmds[] =
        {"WINREG_OPENHKPT", NDR_WINREG_OPENHKPT, api_winreg_OpenHKPT},
        {"WINREG_OPENHKPN", NDR_WINREG_OPENHKPN, api_winreg_OpenHKPN},
        {"WINREG_QUERYMULTIPLEVALUES2", NDR_WINREG_QUERYMULTIPLEVALUES2, api_winreg_QueryMultipleValues2},
+       {"WINREG_DELETEKEYEX", NDR_WINREG_DELETEKEYEX, api_winreg_DeleteKeyEx},
 };
 
 void winreg_get_pipe_fns(struct api_struct **fns, int *n_fns)
@@ -3122,6 +3196,12 @@ NTSTATUS rpc_winreg_dispatch(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, c
                        return NT_STATUS_OK;
                }
 
+               case NDR_WINREG_DELETEKEYEX: {
+                       struct winreg_DeleteKeyEx *r = (struct winreg_DeleteKeyEx *)_r;
+                       r->out.result = _winreg_DeleteKeyEx(cli->pipes_struct, r);
+                       return NT_STATUS_OK;
+               }
+
                default:
                        return NT_STATUS_NOT_IMPLEMENTED;
        }
index f259150e5b7a03c13fb9c7979047b00e530f7bb3..9185b1bb4762aa6d68a3f242e9ec0e4f0ad6982b 100644 (file)
@@ -36,6 +36,7 @@ WERROR _winreg_SaveKeyEx(pipes_struct *p, struct winreg_SaveKeyEx *r);
 WERROR _winreg_OpenHKPT(pipes_struct *p, struct winreg_OpenHKPT *r);
 WERROR _winreg_OpenHKPN(pipes_struct *p, struct winreg_OpenHKPN *r);
 WERROR _winreg_QueryMultipleValues2(pipes_struct *p, struct winreg_QueryMultipleValues2 *r);
+WERROR _winreg_DeleteKeyEx(pipes_struct *p, struct winreg_DeleteKeyEx *r);
 void winreg_get_pipe_fns(struct api_struct **fns, int *n_fns);
 NTSTATUS rpc_winreg_dispatch(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, const struct ndr_interface_table *table, uint32_t opnum, void *r);
 WERROR _winreg_OpenHKCR(pipes_struct *p, struct winreg_OpenHKCR *r);
@@ -73,5 +74,6 @@ WERROR _winreg_SaveKeyEx(pipes_struct *p, struct winreg_SaveKeyEx *r);
 WERROR _winreg_OpenHKPT(pipes_struct *p, struct winreg_OpenHKPT *r);
 WERROR _winreg_OpenHKPN(pipes_struct *p, struct winreg_OpenHKPN *r);
 WERROR _winreg_QueryMultipleValues2(pipes_struct *p, struct winreg_QueryMultipleValues2 *r);
+WERROR _winreg_DeleteKeyEx(pipes_struct *p, struct winreg_DeleteKeyEx *r);
 NTSTATUS rpc_winreg_init(void);
 #endif /* __SRV_WINREG__ */
index 02596cdd8e0d995b5c7901fa48f54361e617522d..aa05148583a9804bf24ea4c11511a4800ed1f1cf 100644 (file)
@@ -634,4 +634,19 @@ struct winreg_QueryMultipleValues2 {
 
 };
 
+
+struct winreg_DeleteKeyEx {
+       struct {
+               struct policy_handle *handle;/* [ref] */
+               struct winreg_String *key;/* [ref] */
+               uint32_t access_mask;
+               uint32_t reserved;
+       } in;
+
+       struct {
+               WERROR result;
+       } out;
+
+};
+
 #endif /* _HEADER_winreg */