LCOV - code coverage report
Current view: top level - bin/default/librpc/gen_ndr - ndr_witness_c.c (source / functions) Hit Total Coverage
Test: coverage report for master 2f515e9b Lines: 0 491 0.0 %
Date: 2024-04-21 15:09:00 Functions: 0 40 0.0 %

          Line data    Source code
       1             : /* client functions auto-generated by pidl */
       2             : 
       3             : #include "includes.h"
       4             : #include <tevent.h>
       5             : #include "lib/util/tevent_ntstatus.h"
       6             : #include "bin/default/librpc/gen_ndr/ndr_witness.h"
       7             : #include "bin/default/librpc/gen_ndr/ndr_witness_c.h"
       8             : 
       9             : /* witness - client functions generated by pidl */
      10             : 
      11             : struct dcerpc_witness_GetInterfaceList_r_state {
      12             :         TALLOC_CTX *out_mem_ctx;
      13             : };
      14             : 
      15             : static void dcerpc_witness_GetInterfaceList_r_done(struct tevent_req *subreq);
      16             : 
      17           0 : struct tevent_req *dcerpc_witness_GetInterfaceList_r_send(TALLOC_CTX *mem_ctx,
      18             :         struct tevent_context *ev,
      19             :         struct dcerpc_binding_handle *h,
      20             :         struct witness_GetInterfaceList *r)
      21             : {
      22           0 :         struct tevent_req *req;
      23           0 :         struct dcerpc_witness_GetInterfaceList_r_state *state;
      24           0 :         struct tevent_req *subreq;
      25             : 
      26           0 :         req = tevent_req_create(mem_ctx, &state,
      27             :                                 struct dcerpc_witness_GetInterfaceList_r_state);
      28           0 :         if (req == NULL) {
      29           0 :                 return NULL;
      30             :         }
      31             : 
      32           0 :         state->out_mem_ctx = talloc_new(state);
      33           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
      34           0 :                 return tevent_req_post(req, ev);
      35             :         }
      36             : 
      37           0 :         subreq = dcerpc_binding_handle_call_send(state, ev, h,
      38             :                         NULL, &ndr_table_witness,
      39           0 :                         NDR_WITNESS_GETINTERFACELIST, state->out_mem_ctx, r);
      40           0 :         if (tevent_req_nomem(subreq, req)) {
      41           0 :                 return tevent_req_post(req, ev);
      42             :         }
      43           0 :         tevent_req_set_callback(subreq, dcerpc_witness_GetInterfaceList_r_done, req);
      44             : 
      45           0 :         return req;
      46             : }
      47             : 
      48           0 : static void dcerpc_witness_GetInterfaceList_r_done(struct tevent_req *subreq)
      49             : {
      50           0 :         struct tevent_req *req =
      51           0 :                 tevent_req_callback_data(subreq,
      52             :                 struct tevent_req);
      53           0 :         NTSTATUS status;
      54             : 
      55           0 :         status = dcerpc_binding_handle_call_recv(subreq);
      56           0 :         TALLOC_FREE(subreq);
      57           0 :         if (tevent_req_nterror(req, status)) {
      58           0 :                 return;
      59             :         }
      60             : 
      61           0 :         tevent_req_done(req);
      62             : }
      63             : 
      64           0 : NTSTATUS dcerpc_witness_GetInterfaceList_r_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx)
      65             : {
      66           0 :         struct dcerpc_witness_GetInterfaceList_r_state *state =
      67           0 :                 tevent_req_data(req,
      68             :                 struct dcerpc_witness_GetInterfaceList_r_state);
      69           0 :         NTSTATUS status;
      70             : 
      71           0 :         if (tevent_req_is_nterror(req, &status)) {
      72           0 :                 tevent_req_received(req);
      73           0 :                 return status;
      74             :         }
      75             : 
      76           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
      77             : 
      78           0 :         tevent_req_received(req);
      79           0 :         return NT_STATUS_OK;
      80             : }
      81             : 
      82           0 : NTSTATUS dcerpc_witness_GetInterfaceList_r(struct dcerpc_binding_handle *h, TALLOC_CTX *mem_ctx, struct witness_GetInterfaceList *r)
      83             : {
      84           0 :         NTSTATUS status;
      85             : 
      86           0 :         status = dcerpc_binding_handle_call(h,
      87             :                         NULL, &ndr_table_witness,
      88             :                         NDR_WITNESS_GETINTERFACELIST, mem_ctx, r);
      89             : 
      90           0 :         return status;
      91             : }
      92             : 
      93             : struct dcerpc_witness_GetInterfaceList_state {
      94             :         struct witness_GetInterfaceList orig;
      95             :         struct witness_GetInterfaceList tmp;
      96             :         TALLOC_CTX *out_mem_ctx;
      97             : };
      98             : 
      99             : static void dcerpc_witness_GetInterfaceList_done(struct tevent_req *subreq);
     100             : 
     101           0 : struct tevent_req *dcerpc_witness_GetInterfaceList_send(TALLOC_CTX *mem_ctx,
     102             :                                                         struct tevent_context *ev,
     103             :                                                         struct dcerpc_binding_handle *h,
     104             :                                                         struct witness_interfaceList **_interface_list /* [out] [ref] */)
     105             : {
     106           0 :         struct tevent_req *req;
     107           0 :         struct dcerpc_witness_GetInterfaceList_state *state;
     108           0 :         struct tevent_req *subreq;
     109             : 
     110           0 :         req = tevent_req_create(mem_ctx, &state,
     111             :                                 struct dcerpc_witness_GetInterfaceList_state);
     112           0 :         if (req == NULL) {
     113           0 :                 return NULL;
     114             :         }
     115           0 :         state->out_mem_ctx = NULL;
     116             : 
     117             :         /* In parameters */
     118             : 
     119             :         /* Out parameters */
     120           0 :         state->orig.out.interface_list = _interface_list;
     121             : 
     122             :         /* Result */
     123           0 :         NDR_ZERO_STRUCT(state->orig.out.result);
     124             : 
     125           0 :         state->out_mem_ctx = talloc_named_const(state, 0,
     126             :                              "dcerpc_witness_GetInterfaceList_out_memory");
     127           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     128           0 :                 return tevent_req_post(req, ev);
     129             :         }
     130             : 
     131             :         /* make a temporary copy, that we pass to the dispatch function */
     132           0 :         state->tmp = state->orig;
     133             : 
     134           0 :         subreq = dcerpc_witness_GetInterfaceList_r_send(state, ev, h, &state->tmp);
     135           0 :         if (tevent_req_nomem(subreq, req)) {
     136           0 :                 return tevent_req_post(req, ev);
     137             :         }
     138           0 :         tevent_req_set_callback(subreq, dcerpc_witness_GetInterfaceList_done, req);
     139           0 :         return req;
     140             : }
     141             : 
     142           0 : static void dcerpc_witness_GetInterfaceList_done(struct tevent_req *subreq)
     143             : {
     144           0 :         struct tevent_req *req = tevent_req_callback_data(
     145             :                 subreq, struct tevent_req);
     146           0 :         struct dcerpc_witness_GetInterfaceList_state *state = tevent_req_data(
     147             :                 req, struct dcerpc_witness_GetInterfaceList_state);
     148           0 :         NTSTATUS status;
     149           0 :         TALLOC_CTX *mem_ctx;
     150             : 
     151           0 :         if (state->out_mem_ctx) {
     152           0 :                 mem_ctx = state->out_mem_ctx;
     153             :         } else {
     154           0 :                 mem_ctx = state;
     155             :         }
     156             : 
     157           0 :         status = dcerpc_witness_GetInterfaceList_r_recv(subreq, mem_ctx);
     158           0 :         TALLOC_FREE(subreq);
     159           0 :         if (tevent_req_nterror(req, status)) {
     160           0 :                 return;
     161             :         }
     162             : 
     163             :         /* Copy out parameters */
     164           0 :         *state->orig.out.interface_list = *state->tmp.out.interface_list;
     165             : 
     166             :         /* Copy result */
     167           0 :         state->orig.out.result = state->tmp.out.result;
     168             : 
     169             :         /* Reset temporary structure */
     170           0 :         NDR_ZERO_STRUCT(state->tmp);
     171             : 
     172           0 :         tevent_req_done(req);
     173             : }
     174             : 
     175           0 : NTSTATUS dcerpc_witness_GetInterfaceList_recv(struct tevent_req *req,
     176             :                                               TALLOC_CTX *mem_ctx,
     177             :                                               WERROR *result)
     178             : {
     179           0 :         struct dcerpc_witness_GetInterfaceList_state *state = tevent_req_data(
     180             :                 req, struct dcerpc_witness_GetInterfaceList_state);
     181           0 :         NTSTATUS status;
     182             : 
     183           0 :         if (tevent_req_is_nterror(req, &status)) {
     184           0 :                 tevent_req_received(req);
     185           0 :                 return status;
     186             :         }
     187             : 
     188             :         /* Steal possible out parameters to the callers context */
     189           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     190             : 
     191             :         /* Return result */
     192           0 :         *result = state->orig.out.result;
     193             : 
     194           0 :         tevent_req_received(req);
     195           0 :         return NT_STATUS_OK;
     196             : }
     197             : 
     198           0 : NTSTATUS dcerpc_witness_GetInterfaceList(struct dcerpc_binding_handle *h,
     199             :                                          TALLOC_CTX *mem_ctx,
     200             :                                          struct witness_interfaceList **_interface_list /* [out] [ref] */,
     201             :                                          WERROR *result)
     202             : {
     203           0 :         struct witness_GetInterfaceList r;
     204           0 :         NTSTATUS status;
     205             : 
     206             :         /* In parameters */
     207             : 
     208             :         /* Out parameters */
     209           0 :         r.out.interface_list = _interface_list;
     210             : 
     211             :         /* Result */
     212           0 :         NDR_ZERO_STRUCT(r.out.result);
     213             : 
     214           0 :         status = dcerpc_witness_GetInterfaceList_r(h, mem_ctx, &r);
     215           0 :         if (!NT_STATUS_IS_OK(status)) {
     216           0 :                 return status;
     217             :         }
     218             : 
     219             :         /* Return variables */
     220           0 :         *_interface_list = *r.out.interface_list;
     221             : 
     222             :         /* Return result */
     223           0 :         *result = r.out.result;
     224             : 
     225           0 :         return NT_STATUS_OK;
     226             : }
     227             : 
     228             : struct dcerpc_witness_Register_r_state {
     229             :         TALLOC_CTX *out_mem_ctx;
     230             : };
     231             : 
     232             : static void dcerpc_witness_Register_r_done(struct tevent_req *subreq);
     233             : 
     234           0 : struct tevent_req *dcerpc_witness_Register_r_send(TALLOC_CTX *mem_ctx,
     235             :         struct tevent_context *ev,
     236             :         struct dcerpc_binding_handle *h,
     237             :         struct witness_Register *r)
     238             : {
     239           0 :         struct tevent_req *req;
     240           0 :         struct dcerpc_witness_Register_r_state *state;
     241           0 :         struct tevent_req *subreq;
     242             : 
     243           0 :         req = tevent_req_create(mem_ctx, &state,
     244             :                                 struct dcerpc_witness_Register_r_state);
     245           0 :         if (req == NULL) {
     246           0 :                 return NULL;
     247             :         }
     248             : 
     249           0 :         state->out_mem_ctx = talloc_new(state);
     250           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     251           0 :                 return tevent_req_post(req, ev);
     252             :         }
     253             : 
     254           0 :         subreq = dcerpc_binding_handle_call_send(state, ev, h,
     255             :                         NULL, &ndr_table_witness,
     256           0 :                         NDR_WITNESS_REGISTER, state->out_mem_ctx, r);
     257           0 :         if (tevent_req_nomem(subreq, req)) {
     258           0 :                 return tevent_req_post(req, ev);
     259             :         }
     260           0 :         tevent_req_set_callback(subreq, dcerpc_witness_Register_r_done, req);
     261             : 
     262           0 :         return req;
     263             : }
     264             : 
     265           0 : static void dcerpc_witness_Register_r_done(struct tevent_req *subreq)
     266             : {
     267           0 :         struct tevent_req *req =
     268           0 :                 tevent_req_callback_data(subreq,
     269             :                 struct tevent_req);
     270           0 :         NTSTATUS status;
     271             : 
     272           0 :         status = dcerpc_binding_handle_call_recv(subreq);
     273           0 :         TALLOC_FREE(subreq);
     274           0 :         if (tevent_req_nterror(req, status)) {
     275           0 :                 return;
     276             :         }
     277             : 
     278           0 :         tevent_req_done(req);
     279             : }
     280             : 
     281           0 : NTSTATUS dcerpc_witness_Register_r_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx)
     282             : {
     283           0 :         struct dcerpc_witness_Register_r_state *state =
     284           0 :                 tevent_req_data(req,
     285             :                 struct dcerpc_witness_Register_r_state);
     286           0 :         NTSTATUS status;
     287             : 
     288           0 :         if (tevent_req_is_nterror(req, &status)) {
     289           0 :                 tevent_req_received(req);
     290           0 :                 return status;
     291             :         }
     292             : 
     293           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     294             : 
     295           0 :         tevent_req_received(req);
     296           0 :         return NT_STATUS_OK;
     297             : }
     298             : 
     299           0 : NTSTATUS dcerpc_witness_Register_r(struct dcerpc_binding_handle *h, TALLOC_CTX *mem_ctx, struct witness_Register *r)
     300             : {
     301           0 :         NTSTATUS status;
     302             : 
     303           0 :         status = dcerpc_binding_handle_call(h,
     304             :                         NULL, &ndr_table_witness,
     305             :                         NDR_WITNESS_REGISTER, mem_ctx, r);
     306             : 
     307           0 :         return status;
     308             : }
     309             : 
     310             : struct dcerpc_witness_Register_state {
     311             :         struct witness_Register orig;
     312             :         struct witness_Register tmp;
     313             :         TALLOC_CTX *out_mem_ctx;
     314             : };
     315             : 
     316             : static void dcerpc_witness_Register_done(struct tevent_req *subreq);
     317             : 
     318           0 : struct tevent_req *dcerpc_witness_Register_send(TALLOC_CTX *mem_ctx,
     319             :                                                 struct tevent_context *ev,
     320             :                                                 struct dcerpc_binding_handle *h,
     321             :                                                 struct policy_handle *_context_handle /* [out] [ref] */,
     322             :                                                 enum witness_version _version /* [in]  */,
     323             :                                                 const char *_net_name /* [in] [charset(UTF16),unique] */,
     324             :                                                 const char *_ip_address /* [in] [charset(UTF16),unique] */,
     325             :                                                 const char *_client_computer_name /* [in] [charset(UTF16),unique] */)
     326             : {
     327           0 :         struct tevent_req *req;
     328           0 :         struct dcerpc_witness_Register_state *state;
     329           0 :         struct tevent_req *subreq;
     330             : 
     331           0 :         req = tevent_req_create(mem_ctx, &state,
     332             :                                 struct dcerpc_witness_Register_state);
     333           0 :         if (req == NULL) {
     334           0 :                 return NULL;
     335             :         }
     336           0 :         state->out_mem_ctx = NULL;
     337             : 
     338             :         /* In parameters */
     339           0 :         state->orig.in.version = _version;
     340           0 :         state->orig.in.net_name = _net_name;
     341           0 :         state->orig.in.ip_address = _ip_address;
     342           0 :         state->orig.in.client_computer_name = _client_computer_name;
     343             : 
     344             :         /* Out parameters */
     345           0 :         state->orig.out.context_handle = _context_handle;
     346             : 
     347             :         /* Result */
     348           0 :         NDR_ZERO_STRUCT(state->orig.out.result);
     349             : 
     350           0 :         state->out_mem_ctx = talloc_named_const(state, 0,
     351             :                              "dcerpc_witness_Register_out_memory");
     352           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     353           0 :                 return tevent_req_post(req, ev);
     354             :         }
     355             : 
     356             :         /* make a temporary copy, that we pass to the dispatch function */
     357           0 :         state->tmp = state->orig;
     358             : 
     359           0 :         subreq = dcerpc_witness_Register_r_send(state, ev, h, &state->tmp);
     360           0 :         if (tevent_req_nomem(subreq, req)) {
     361           0 :                 return tevent_req_post(req, ev);
     362             :         }
     363           0 :         tevent_req_set_callback(subreq, dcerpc_witness_Register_done, req);
     364           0 :         return req;
     365             : }
     366             : 
     367           0 : static void dcerpc_witness_Register_done(struct tevent_req *subreq)
     368             : {
     369           0 :         struct tevent_req *req = tevent_req_callback_data(
     370             :                 subreq, struct tevent_req);
     371           0 :         struct dcerpc_witness_Register_state *state = tevent_req_data(
     372             :                 req, struct dcerpc_witness_Register_state);
     373           0 :         NTSTATUS status;
     374           0 :         TALLOC_CTX *mem_ctx;
     375             : 
     376           0 :         if (state->out_mem_ctx) {
     377           0 :                 mem_ctx = state->out_mem_ctx;
     378             :         } else {
     379           0 :                 mem_ctx = state;
     380             :         }
     381             : 
     382           0 :         status = dcerpc_witness_Register_r_recv(subreq, mem_ctx);
     383           0 :         TALLOC_FREE(subreq);
     384           0 :         if (tevent_req_nterror(req, status)) {
     385           0 :                 return;
     386             :         }
     387             : 
     388             :         /* Copy out parameters */
     389           0 :         *state->orig.out.context_handle = *state->tmp.out.context_handle;
     390             : 
     391             :         /* Copy result */
     392           0 :         state->orig.out.result = state->tmp.out.result;
     393             : 
     394             :         /* Reset temporary structure */
     395           0 :         NDR_ZERO_STRUCT(state->tmp);
     396             : 
     397           0 :         tevent_req_done(req);
     398             : }
     399             : 
     400           0 : NTSTATUS dcerpc_witness_Register_recv(struct tevent_req *req,
     401             :                                       TALLOC_CTX *mem_ctx,
     402             :                                       WERROR *result)
     403             : {
     404           0 :         struct dcerpc_witness_Register_state *state = tevent_req_data(
     405             :                 req, struct dcerpc_witness_Register_state);
     406           0 :         NTSTATUS status;
     407             : 
     408           0 :         if (tevent_req_is_nterror(req, &status)) {
     409           0 :                 tevent_req_received(req);
     410           0 :                 return status;
     411             :         }
     412             : 
     413             :         /* Steal possible out parameters to the callers context */
     414           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     415             : 
     416             :         /* Return result */
     417           0 :         *result = state->orig.out.result;
     418             : 
     419           0 :         tevent_req_received(req);
     420           0 :         return NT_STATUS_OK;
     421             : }
     422             : 
     423           0 : NTSTATUS dcerpc_witness_Register(struct dcerpc_binding_handle *h,
     424             :                                  TALLOC_CTX *mem_ctx,
     425             :                                  struct policy_handle *_context_handle /* [out] [ref] */,
     426             :                                  enum witness_version _version /* [in]  */,
     427             :                                  const char *_net_name /* [in] [charset(UTF16),unique] */,
     428             :                                  const char *_ip_address /* [in] [charset(UTF16),unique] */,
     429             :                                  const char *_client_computer_name /* [in] [charset(UTF16),unique] */,
     430             :                                  WERROR *result)
     431             : {
     432           0 :         struct witness_Register r;
     433           0 :         NTSTATUS status;
     434             : 
     435             :         /* In parameters */
     436           0 :         r.in.version = _version;
     437           0 :         r.in.net_name = _net_name;
     438           0 :         r.in.ip_address = _ip_address;
     439           0 :         r.in.client_computer_name = _client_computer_name;
     440             : 
     441             :         /* Out parameters */
     442           0 :         r.out.context_handle = _context_handle;
     443             : 
     444             :         /* Result */
     445           0 :         NDR_ZERO_STRUCT(r.out.result);
     446             : 
     447           0 :         status = dcerpc_witness_Register_r(h, mem_ctx, &r);
     448           0 :         if (!NT_STATUS_IS_OK(status)) {
     449           0 :                 return status;
     450             :         }
     451             : 
     452             :         /* Return variables */
     453           0 :         *_context_handle = *r.out.context_handle;
     454             : 
     455             :         /* Return result */
     456           0 :         *result = r.out.result;
     457             : 
     458           0 :         return NT_STATUS_OK;
     459             : }
     460             : 
     461             : struct dcerpc_witness_UnRegister_r_state {
     462             :         TALLOC_CTX *out_mem_ctx;
     463             : };
     464             : 
     465             : static void dcerpc_witness_UnRegister_r_done(struct tevent_req *subreq);
     466             : 
     467           0 : struct tevent_req *dcerpc_witness_UnRegister_r_send(TALLOC_CTX *mem_ctx,
     468             :         struct tevent_context *ev,
     469             :         struct dcerpc_binding_handle *h,
     470             :         struct witness_UnRegister *r)
     471             : {
     472           0 :         struct tevent_req *req;
     473           0 :         struct dcerpc_witness_UnRegister_r_state *state;
     474           0 :         struct tevent_req *subreq;
     475             : 
     476           0 :         req = tevent_req_create(mem_ctx, &state,
     477             :                                 struct dcerpc_witness_UnRegister_r_state);
     478           0 :         if (req == NULL) {
     479           0 :                 return NULL;
     480             :         }
     481             : 
     482           0 :         state->out_mem_ctx = NULL;
     483             : 
     484           0 :         subreq = dcerpc_binding_handle_call_send(state, ev, h,
     485             :                         NULL, &ndr_table_witness,
     486             :                         NDR_WITNESS_UNREGISTER, state, r);
     487           0 :         if (tevent_req_nomem(subreq, req)) {
     488           0 :                 return tevent_req_post(req, ev);
     489             :         }
     490           0 :         tevent_req_set_callback(subreq, dcerpc_witness_UnRegister_r_done, req);
     491             : 
     492           0 :         return req;
     493             : }
     494             : 
     495           0 : static void dcerpc_witness_UnRegister_r_done(struct tevent_req *subreq)
     496             : {
     497           0 :         struct tevent_req *req =
     498           0 :                 tevent_req_callback_data(subreq,
     499             :                 struct tevent_req);
     500           0 :         NTSTATUS status;
     501             : 
     502           0 :         status = dcerpc_binding_handle_call_recv(subreq);
     503           0 :         TALLOC_FREE(subreq);
     504           0 :         if (tevent_req_nterror(req, status)) {
     505           0 :                 return;
     506             :         }
     507             : 
     508           0 :         tevent_req_done(req);
     509             : }
     510             : 
     511           0 : NTSTATUS dcerpc_witness_UnRegister_r_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx)
     512             : {
     513           0 :         struct dcerpc_witness_UnRegister_r_state *state =
     514           0 :                 tevent_req_data(req,
     515             :                 struct dcerpc_witness_UnRegister_r_state);
     516           0 :         NTSTATUS status;
     517             : 
     518           0 :         if (tevent_req_is_nterror(req, &status)) {
     519           0 :                 tevent_req_received(req);
     520           0 :                 return status;
     521             :         }
     522             : 
     523           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     524             : 
     525           0 :         tevent_req_received(req);
     526           0 :         return NT_STATUS_OK;
     527             : }
     528             : 
     529           0 : NTSTATUS dcerpc_witness_UnRegister_r(struct dcerpc_binding_handle *h, TALLOC_CTX *mem_ctx, struct witness_UnRegister *r)
     530             : {
     531           0 :         NTSTATUS status;
     532             : 
     533           0 :         status = dcerpc_binding_handle_call(h,
     534             :                         NULL, &ndr_table_witness,
     535             :                         NDR_WITNESS_UNREGISTER, mem_ctx, r);
     536             : 
     537           0 :         return status;
     538             : }
     539             : 
     540             : struct dcerpc_witness_UnRegister_state {
     541             :         struct witness_UnRegister orig;
     542             :         struct witness_UnRegister tmp;
     543             :         TALLOC_CTX *out_mem_ctx;
     544             : };
     545             : 
     546             : static void dcerpc_witness_UnRegister_done(struct tevent_req *subreq);
     547             : 
     548           0 : struct tevent_req *dcerpc_witness_UnRegister_send(TALLOC_CTX *mem_ctx,
     549             :                                                   struct tevent_context *ev,
     550             :                                                   struct dcerpc_binding_handle *h,
     551             :                                                   struct policy_handle _context_handle /* [in]  */)
     552             : {
     553           0 :         struct tevent_req *req;
     554           0 :         struct dcerpc_witness_UnRegister_state *state;
     555           0 :         struct tevent_req *subreq;
     556             : 
     557           0 :         req = tevent_req_create(mem_ctx, &state,
     558             :                                 struct dcerpc_witness_UnRegister_state);
     559           0 :         if (req == NULL) {
     560           0 :                 return NULL;
     561             :         }
     562           0 :         state->out_mem_ctx = NULL;
     563             : 
     564             :         /* In parameters */
     565           0 :         state->orig.in.context_handle = _context_handle;
     566             : 
     567             :         /* Out parameters */
     568             : 
     569             :         /* Result */
     570           0 :         NDR_ZERO_STRUCT(state->orig.out.result);
     571             : 
     572             :         /* make a temporary copy, that we pass to the dispatch function */
     573           0 :         state->tmp = state->orig;
     574             : 
     575           0 :         subreq = dcerpc_witness_UnRegister_r_send(state, ev, h, &state->tmp);
     576           0 :         if (tevent_req_nomem(subreq, req)) {
     577           0 :                 return tevent_req_post(req, ev);
     578             :         }
     579           0 :         tevent_req_set_callback(subreq, dcerpc_witness_UnRegister_done, req);
     580           0 :         return req;
     581             : }
     582             : 
     583           0 : static void dcerpc_witness_UnRegister_done(struct tevent_req *subreq)
     584             : {
     585           0 :         struct tevent_req *req = tevent_req_callback_data(
     586             :                 subreq, struct tevent_req);
     587           0 :         struct dcerpc_witness_UnRegister_state *state = tevent_req_data(
     588             :                 req, struct dcerpc_witness_UnRegister_state);
     589           0 :         NTSTATUS status;
     590           0 :         TALLOC_CTX *mem_ctx;
     591             : 
     592           0 :         if (state->out_mem_ctx) {
     593           0 :                 mem_ctx = state->out_mem_ctx;
     594             :         } else {
     595           0 :                 mem_ctx = state;
     596             :         }
     597             : 
     598           0 :         status = dcerpc_witness_UnRegister_r_recv(subreq, mem_ctx);
     599           0 :         TALLOC_FREE(subreq);
     600           0 :         if (tevent_req_nterror(req, status)) {
     601           0 :                 return;
     602             :         }
     603             : 
     604             :         /* Copy out parameters */
     605             : 
     606             :         /* Copy result */
     607           0 :         state->orig.out.result = state->tmp.out.result;
     608             : 
     609             :         /* Reset temporary structure */
     610           0 :         NDR_ZERO_STRUCT(state->tmp);
     611             : 
     612           0 :         tevent_req_done(req);
     613             : }
     614             : 
     615           0 : NTSTATUS dcerpc_witness_UnRegister_recv(struct tevent_req *req,
     616             :                                         TALLOC_CTX *mem_ctx,
     617             :                                         WERROR *result)
     618             : {
     619           0 :         struct dcerpc_witness_UnRegister_state *state = tevent_req_data(
     620             :                 req, struct dcerpc_witness_UnRegister_state);
     621           0 :         NTSTATUS status;
     622             : 
     623           0 :         if (tevent_req_is_nterror(req, &status)) {
     624           0 :                 tevent_req_received(req);
     625           0 :                 return status;
     626             :         }
     627             : 
     628             :         /* Steal possible out parameters to the callers context */
     629           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     630             : 
     631             :         /* Return result */
     632           0 :         *result = state->orig.out.result;
     633             : 
     634           0 :         tevent_req_received(req);
     635           0 :         return NT_STATUS_OK;
     636             : }
     637             : 
     638           0 : NTSTATUS dcerpc_witness_UnRegister(struct dcerpc_binding_handle *h,
     639             :                                    TALLOC_CTX *mem_ctx,
     640             :                                    struct policy_handle _context_handle /* [in]  */,
     641             :                                    WERROR *result)
     642             : {
     643           0 :         struct witness_UnRegister r;
     644           0 :         NTSTATUS status;
     645             : 
     646             :         /* In parameters */
     647           0 :         r.in.context_handle = _context_handle;
     648             : 
     649             :         /* Out parameters */
     650             : 
     651             :         /* Result */
     652           0 :         NDR_ZERO_STRUCT(r.out.result);
     653             : 
     654           0 :         status = dcerpc_witness_UnRegister_r(h, mem_ctx, &r);
     655           0 :         if (!NT_STATUS_IS_OK(status)) {
     656           0 :                 return status;
     657             :         }
     658             : 
     659             :         /* Return variables */
     660             : 
     661             :         /* Return result */
     662           0 :         *result = r.out.result;
     663             : 
     664           0 :         return NT_STATUS_OK;
     665             : }
     666             : 
     667             : struct dcerpc_witness_AsyncNotify_r_state {
     668             :         TALLOC_CTX *out_mem_ctx;
     669             : };
     670             : 
     671             : static void dcerpc_witness_AsyncNotify_r_done(struct tevent_req *subreq);
     672             : 
     673           0 : struct tevent_req *dcerpc_witness_AsyncNotify_r_send(TALLOC_CTX *mem_ctx,
     674             :         struct tevent_context *ev,
     675             :         struct dcerpc_binding_handle *h,
     676             :         struct witness_AsyncNotify *r)
     677             : {
     678           0 :         struct tevent_req *req;
     679           0 :         struct dcerpc_witness_AsyncNotify_r_state *state;
     680           0 :         struct tevent_req *subreq;
     681             : 
     682           0 :         req = tevent_req_create(mem_ctx, &state,
     683             :                                 struct dcerpc_witness_AsyncNotify_r_state);
     684           0 :         if (req == NULL) {
     685           0 :                 return NULL;
     686             :         }
     687             : 
     688           0 :         state->out_mem_ctx = talloc_new(state);
     689           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     690           0 :                 return tevent_req_post(req, ev);
     691             :         }
     692             : 
     693           0 :         subreq = dcerpc_binding_handle_call_send(state, ev, h,
     694             :                         NULL, &ndr_table_witness,
     695           0 :                         NDR_WITNESS_ASYNCNOTIFY, state->out_mem_ctx, r);
     696           0 :         if (tevent_req_nomem(subreq, req)) {
     697           0 :                 return tevent_req_post(req, ev);
     698             :         }
     699           0 :         tevent_req_set_callback(subreq, dcerpc_witness_AsyncNotify_r_done, req);
     700             : 
     701           0 :         return req;
     702             : }
     703             : 
     704           0 : static void dcerpc_witness_AsyncNotify_r_done(struct tevent_req *subreq)
     705             : {
     706           0 :         struct tevent_req *req =
     707           0 :                 tevent_req_callback_data(subreq,
     708             :                 struct tevent_req);
     709           0 :         NTSTATUS status;
     710             : 
     711           0 :         status = dcerpc_binding_handle_call_recv(subreq);
     712           0 :         TALLOC_FREE(subreq);
     713           0 :         if (tevent_req_nterror(req, status)) {
     714           0 :                 return;
     715             :         }
     716             : 
     717           0 :         tevent_req_done(req);
     718             : }
     719             : 
     720           0 : NTSTATUS dcerpc_witness_AsyncNotify_r_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx)
     721             : {
     722           0 :         struct dcerpc_witness_AsyncNotify_r_state *state =
     723           0 :                 tevent_req_data(req,
     724             :                 struct dcerpc_witness_AsyncNotify_r_state);
     725           0 :         NTSTATUS status;
     726             : 
     727           0 :         if (tevent_req_is_nterror(req, &status)) {
     728           0 :                 tevent_req_received(req);
     729           0 :                 return status;
     730             :         }
     731             : 
     732           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     733             : 
     734           0 :         tevent_req_received(req);
     735           0 :         return NT_STATUS_OK;
     736             : }
     737             : 
     738           0 : NTSTATUS dcerpc_witness_AsyncNotify_r(struct dcerpc_binding_handle *h, TALLOC_CTX *mem_ctx, struct witness_AsyncNotify *r)
     739             : {
     740           0 :         NTSTATUS status;
     741             : 
     742           0 :         status = dcerpc_binding_handle_call(h,
     743             :                         NULL, &ndr_table_witness,
     744             :                         NDR_WITNESS_ASYNCNOTIFY, mem_ctx, r);
     745             : 
     746           0 :         return status;
     747             : }
     748             : 
     749             : struct dcerpc_witness_AsyncNotify_state {
     750             :         struct witness_AsyncNotify orig;
     751             :         struct witness_AsyncNotify tmp;
     752             :         TALLOC_CTX *out_mem_ctx;
     753             : };
     754             : 
     755             : static void dcerpc_witness_AsyncNotify_done(struct tevent_req *subreq);
     756             : 
     757           0 : struct tevent_req *dcerpc_witness_AsyncNotify_send(TALLOC_CTX *mem_ctx,
     758             :                                                    struct tevent_context *ev,
     759             :                                                    struct dcerpc_binding_handle *h,
     760             :                                                    struct policy_handle _context_handle /* [in]  */,
     761             :                                                    struct witness_notifyResponse **_response /* [out] [ref] */)
     762             : {
     763           0 :         struct tevent_req *req;
     764           0 :         struct dcerpc_witness_AsyncNotify_state *state;
     765           0 :         struct tevent_req *subreq;
     766             : 
     767           0 :         req = tevent_req_create(mem_ctx, &state,
     768             :                                 struct dcerpc_witness_AsyncNotify_state);
     769           0 :         if (req == NULL) {
     770           0 :                 return NULL;
     771             :         }
     772           0 :         state->out_mem_ctx = NULL;
     773             : 
     774             :         /* In parameters */
     775           0 :         state->orig.in.context_handle = _context_handle;
     776             : 
     777             :         /* Out parameters */
     778           0 :         state->orig.out.response = _response;
     779             : 
     780             :         /* Result */
     781           0 :         NDR_ZERO_STRUCT(state->orig.out.result);
     782             : 
     783           0 :         state->out_mem_ctx = talloc_named_const(state, 0,
     784             :                              "dcerpc_witness_AsyncNotify_out_memory");
     785           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     786           0 :                 return tevent_req_post(req, ev);
     787             :         }
     788             : 
     789             :         /* make a temporary copy, that we pass to the dispatch function */
     790           0 :         state->tmp = state->orig;
     791             : 
     792           0 :         subreq = dcerpc_witness_AsyncNotify_r_send(state, ev, h, &state->tmp);
     793           0 :         if (tevent_req_nomem(subreq, req)) {
     794           0 :                 return tevent_req_post(req, ev);
     795             :         }
     796           0 :         tevent_req_set_callback(subreq, dcerpc_witness_AsyncNotify_done, req);
     797           0 :         return req;
     798             : }
     799             : 
     800           0 : static void dcerpc_witness_AsyncNotify_done(struct tevent_req *subreq)
     801             : {
     802           0 :         struct tevent_req *req = tevent_req_callback_data(
     803             :                 subreq, struct tevent_req);
     804           0 :         struct dcerpc_witness_AsyncNotify_state *state = tevent_req_data(
     805             :                 req, struct dcerpc_witness_AsyncNotify_state);
     806           0 :         NTSTATUS status;
     807           0 :         TALLOC_CTX *mem_ctx;
     808             : 
     809           0 :         if (state->out_mem_ctx) {
     810           0 :                 mem_ctx = state->out_mem_ctx;
     811             :         } else {
     812           0 :                 mem_ctx = state;
     813             :         }
     814             : 
     815           0 :         status = dcerpc_witness_AsyncNotify_r_recv(subreq, mem_ctx);
     816           0 :         TALLOC_FREE(subreq);
     817           0 :         if (tevent_req_nterror(req, status)) {
     818           0 :                 return;
     819             :         }
     820             : 
     821             :         /* Copy out parameters */
     822           0 :         *state->orig.out.response = *state->tmp.out.response;
     823             : 
     824             :         /* Copy result */
     825           0 :         state->orig.out.result = state->tmp.out.result;
     826             : 
     827             :         /* Reset temporary structure */
     828           0 :         NDR_ZERO_STRUCT(state->tmp);
     829             : 
     830           0 :         tevent_req_done(req);
     831             : }
     832             : 
     833           0 : NTSTATUS dcerpc_witness_AsyncNotify_recv(struct tevent_req *req,
     834             :                                          TALLOC_CTX *mem_ctx,
     835             :                                          WERROR *result)
     836             : {
     837           0 :         struct dcerpc_witness_AsyncNotify_state *state = tevent_req_data(
     838             :                 req, struct dcerpc_witness_AsyncNotify_state);
     839           0 :         NTSTATUS status;
     840             : 
     841           0 :         if (tevent_req_is_nterror(req, &status)) {
     842           0 :                 tevent_req_received(req);
     843           0 :                 return status;
     844             :         }
     845             : 
     846             :         /* Steal possible out parameters to the callers context */
     847           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     848             : 
     849             :         /* Return result */
     850           0 :         *result = state->orig.out.result;
     851             : 
     852           0 :         tevent_req_received(req);
     853           0 :         return NT_STATUS_OK;
     854             : }
     855             : 
     856           0 : NTSTATUS dcerpc_witness_AsyncNotify(struct dcerpc_binding_handle *h,
     857             :                                     TALLOC_CTX *mem_ctx,
     858             :                                     struct policy_handle _context_handle /* [in]  */,
     859             :                                     struct witness_notifyResponse **_response /* [out] [ref] */,
     860             :                                     WERROR *result)
     861             : {
     862           0 :         struct witness_AsyncNotify r;
     863           0 :         NTSTATUS status;
     864             : 
     865             :         /* In parameters */
     866           0 :         r.in.context_handle = _context_handle;
     867             : 
     868             :         /* Out parameters */
     869           0 :         r.out.response = _response;
     870             : 
     871             :         /* Result */
     872           0 :         NDR_ZERO_STRUCT(r.out.result);
     873             : 
     874           0 :         status = dcerpc_witness_AsyncNotify_r(h, mem_ctx, &r);
     875           0 :         if (!NT_STATUS_IS_OK(status)) {
     876           0 :                 return status;
     877             :         }
     878             : 
     879             :         /* Return variables */
     880           0 :         *_response = *r.out.response;
     881             : 
     882             :         /* Return result */
     883           0 :         *result = r.out.result;
     884             : 
     885           0 :         return NT_STATUS_OK;
     886             : }
     887             : 
     888             : struct dcerpc_witness_RegisterEx_r_state {
     889             :         TALLOC_CTX *out_mem_ctx;
     890             : };
     891             : 
     892             : static void dcerpc_witness_RegisterEx_r_done(struct tevent_req *subreq);
     893             : 
     894           0 : struct tevent_req *dcerpc_witness_RegisterEx_r_send(TALLOC_CTX *mem_ctx,
     895             :         struct tevent_context *ev,
     896             :         struct dcerpc_binding_handle *h,
     897             :         struct witness_RegisterEx *r)
     898             : {
     899           0 :         struct tevent_req *req;
     900           0 :         struct dcerpc_witness_RegisterEx_r_state *state;
     901           0 :         struct tevent_req *subreq;
     902             : 
     903           0 :         req = tevent_req_create(mem_ctx, &state,
     904             :                                 struct dcerpc_witness_RegisterEx_r_state);
     905           0 :         if (req == NULL) {
     906           0 :                 return NULL;
     907             :         }
     908             : 
     909           0 :         state->out_mem_ctx = talloc_new(state);
     910           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
     911           0 :                 return tevent_req_post(req, ev);
     912             :         }
     913             : 
     914           0 :         subreq = dcerpc_binding_handle_call_send(state, ev, h,
     915             :                         NULL, &ndr_table_witness,
     916           0 :                         NDR_WITNESS_REGISTEREX, state->out_mem_ctx, r);
     917           0 :         if (tevent_req_nomem(subreq, req)) {
     918           0 :                 return tevent_req_post(req, ev);
     919             :         }
     920           0 :         tevent_req_set_callback(subreq, dcerpc_witness_RegisterEx_r_done, req);
     921             : 
     922           0 :         return req;
     923             : }
     924             : 
     925           0 : static void dcerpc_witness_RegisterEx_r_done(struct tevent_req *subreq)
     926             : {
     927           0 :         struct tevent_req *req =
     928           0 :                 tevent_req_callback_data(subreq,
     929             :                 struct tevent_req);
     930           0 :         NTSTATUS status;
     931             : 
     932           0 :         status = dcerpc_binding_handle_call_recv(subreq);
     933           0 :         TALLOC_FREE(subreq);
     934           0 :         if (tevent_req_nterror(req, status)) {
     935           0 :                 return;
     936             :         }
     937             : 
     938           0 :         tevent_req_done(req);
     939             : }
     940             : 
     941           0 : NTSTATUS dcerpc_witness_RegisterEx_r_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx)
     942             : {
     943           0 :         struct dcerpc_witness_RegisterEx_r_state *state =
     944           0 :                 tevent_req_data(req,
     945             :                 struct dcerpc_witness_RegisterEx_r_state);
     946           0 :         NTSTATUS status;
     947             : 
     948           0 :         if (tevent_req_is_nterror(req, &status)) {
     949           0 :                 tevent_req_received(req);
     950           0 :                 return status;
     951             :         }
     952             : 
     953           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
     954             : 
     955           0 :         tevent_req_received(req);
     956           0 :         return NT_STATUS_OK;
     957             : }
     958             : 
     959           0 : NTSTATUS dcerpc_witness_RegisterEx_r(struct dcerpc_binding_handle *h, TALLOC_CTX *mem_ctx, struct witness_RegisterEx *r)
     960             : {
     961           0 :         NTSTATUS status;
     962             : 
     963           0 :         status = dcerpc_binding_handle_call(h,
     964             :                         NULL, &ndr_table_witness,
     965             :                         NDR_WITNESS_REGISTEREX, mem_ctx, r);
     966             : 
     967           0 :         return status;
     968             : }
     969             : 
     970             : struct dcerpc_witness_RegisterEx_state {
     971             :         struct witness_RegisterEx orig;
     972             :         struct witness_RegisterEx tmp;
     973             :         TALLOC_CTX *out_mem_ctx;
     974             : };
     975             : 
     976             : static void dcerpc_witness_RegisterEx_done(struct tevent_req *subreq);
     977             : 
     978           0 : struct tevent_req *dcerpc_witness_RegisterEx_send(TALLOC_CTX *mem_ctx,
     979             :                                                   struct tevent_context *ev,
     980             :                                                   struct dcerpc_binding_handle *h,
     981             :                                                   struct policy_handle *_context_handle /* [out] [ref] */,
     982             :                                                   enum witness_version _version /* [in]  */,
     983             :                                                   const char *_net_name /* [in] [charset(UTF16),unique] */,
     984             :                                                   const char *_share_name /* [in] [charset(UTF16),unique] */,
     985             :                                                   const char *_ip_address /* [in] [charset(UTF16),unique] */,
     986             :                                                   const char *_client_computer_name /* [in] [charset(UTF16),unique] */,
     987             :                                                   uint32_t _flags /* [in]  */,
     988             :                                                   uint32_t _timeout /* [in]  */)
     989             : {
     990           0 :         struct tevent_req *req;
     991           0 :         struct dcerpc_witness_RegisterEx_state *state;
     992           0 :         struct tevent_req *subreq;
     993             : 
     994           0 :         req = tevent_req_create(mem_ctx, &state,
     995             :                                 struct dcerpc_witness_RegisterEx_state);
     996           0 :         if (req == NULL) {
     997           0 :                 return NULL;
     998             :         }
     999           0 :         state->out_mem_ctx = NULL;
    1000             : 
    1001             :         /* In parameters */
    1002           0 :         state->orig.in.version = _version;
    1003           0 :         state->orig.in.net_name = _net_name;
    1004           0 :         state->orig.in.share_name = _share_name;
    1005           0 :         state->orig.in.ip_address = _ip_address;
    1006           0 :         state->orig.in.client_computer_name = _client_computer_name;
    1007           0 :         state->orig.in.flags = _flags;
    1008           0 :         state->orig.in.timeout = _timeout;
    1009             : 
    1010             :         /* Out parameters */
    1011           0 :         state->orig.out.context_handle = _context_handle;
    1012             : 
    1013             :         /* Result */
    1014           0 :         NDR_ZERO_STRUCT(state->orig.out.result);
    1015             : 
    1016           0 :         state->out_mem_ctx = talloc_named_const(state, 0,
    1017             :                              "dcerpc_witness_RegisterEx_out_memory");
    1018           0 :         if (tevent_req_nomem(state->out_mem_ctx, req)) {
    1019           0 :                 return tevent_req_post(req, ev);
    1020             :         }
    1021             : 
    1022             :         /* make a temporary copy, that we pass to the dispatch function */
    1023           0 :         state->tmp = state->orig;
    1024             : 
    1025           0 :         subreq = dcerpc_witness_RegisterEx_r_send(state, ev, h, &state->tmp);
    1026           0 :         if (tevent_req_nomem(subreq, req)) {
    1027           0 :                 return tevent_req_post(req, ev);
    1028             :         }
    1029           0 :         tevent_req_set_callback(subreq, dcerpc_witness_RegisterEx_done, req);
    1030           0 :         return req;
    1031             : }
    1032             : 
    1033           0 : static void dcerpc_witness_RegisterEx_done(struct tevent_req *subreq)
    1034             : {
    1035           0 :         struct tevent_req *req = tevent_req_callback_data(
    1036             :                 subreq, struct tevent_req);
    1037           0 :         struct dcerpc_witness_RegisterEx_state *state = tevent_req_data(
    1038             :                 req, struct dcerpc_witness_RegisterEx_state);
    1039           0 :         NTSTATUS status;
    1040           0 :         TALLOC_CTX *mem_ctx;
    1041             : 
    1042           0 :         if (state->out_mem_ctx) {
    1043           0 :                 mem_ctx = state->out_mem_ctx;
    1044             :         } else {
    1045           0 :                 mem_ctx = state;
    1046             :         }
    1047             : 
    1048           0 :         status = dcerpc_witness_RegisterEx_r_recv(subreq, mem_ctx);
    1049           0 :         TALLOC_FREE(subreq);
    1050           0 :         if (tevent_req_nterror(req, status)) {
    1051           0 :                 return;
    1052             :         }
    1053             : 
    1054             :         /* Copy out parameters */
    1055           0 :         *state->orig.out.context_handle = *state->tmp.out.context_handle;
    1056             : 
    1057             :         /* Copy result */
    1058           0 :         state->orig.out.result = state->tmp.out.result;
    1059             : 
    1060             :         /* Reset temporary structure */
    1061           0 :         NDR_ZERO_STRUCT(state->tmp);
    1062             : 
    1063           0 :         tevent_req_done(req);
    1064             : }
    1065             : 
    1066           0 : NTSTATUS dcerpc_witness_RegisterEx_recv(struct tevent_req *req,
    1067             :                                         TALLOC_CTX *mem_ctx,
    1068             :                                         WERROR *result)
    1069             : {
    1070           0 :         struct dcerpc_witness_RegisterEx_state *state = tevent_req_data(
    1071             :                 req, struct dcerpc_witness_RegisterEx_state);
    1072           0 :         NTSTATUS status;
    1073             : 
    1074           0 :         if (tevent_req_is_nterror(req, &status)) {
    1075           0 :                 tevent_req_received(req);
    1076           0 :                 return status;
    1077             :         }
    1078             : 
    1079             :         /* Steal possible out parameters to the callers context */
    1080           0 :         talloc_steal(mem_ctx, state->out_mem_ctx);
    1081             : 
    1082             :         /* Return result */
    1083           0 :         *result = state->orig.out.result;
    1084             : 
    1085           0 :         tevent_req_received(req);
    1086           0 :         return NT_STATUS_OK;
    1087             : }
    1088             : 
    1089           0 : NTSTATUS dcerpc_witness_RegisterEx(struct dcerpc_binding_handle *h,
    1090             :                                    TALLOC_CTX *mem_ctx,
    1091             :                                    struct policy_handle *_context_handle /* [out] [ref] */,
    1092             :                                    enum witness_version _version /* [in]  */,
    1093             :                                    const char *_net_name /* [in] [charset(UTF16),unique] */,
    1094             :                                    const char *_share_name /* [in] [charset(UTF16),unique] */,
    1095             :                                    const char *_ip_address /* [in] [charset(UTF16),unique] */,
    1096             :                                    const char *_client_computer_name /* [in] [charset(UTF16),unique] */,
    1097             :                                    uint32_t _flags /* [in]  */,
    1098             :                                    uint32_t _timeout /* [in]  */,
    1099             :                                    WERROR *result)
    1100             : {
    1101           0 :         struct witness_RegisterEx r;
    1102           0 :         NTSTATUS status;
    1103             : 
    1104             :         /* In parameters */
    1105           0 :         r.in.version = _version;
    1106           0 :         r.in.net_name = _net_name;
    1107           0 :         r.in.share_name = _share_name;
    1108           0 :         r.in.ip_address = _ip_address;
    1109           0 :         r.in.client_computer_name = _client_computer_name;
    1110           0 :         r.in.flags = _flags;
    1111           0 :         r.in.timeout = _timeout;
    1112             : 
    1113             :         /* Out parameters */
    1114           0 :         r.out.context_handle = _context_handle;
    1115             : 
    1116             :         /* Result */
    1117           0 :         NDR_ZERO_STRUCT(r.out.result);
    1118             : 
    1119           0 :         status = dcerpc_witness_RegisterEx_r(h, mem_ctx, &r);
    1120           0 :         if (!NT_STATUS_IS_OK(status)) {
    1121           0 :                 return status;
    1122             :         }
    1123             : 
    1124             :         /* Return variables */
    1125           0 :         *_context_handle = *r.out.context_handle;
    1126             : 
    1127             :         /* Return result */
    1128           0 :         *result = r.out.result;
    1129             : 
    1130           0 :         return NT_STATUS_OK;
    1131             : }
    1132             : 

Generated by: LCOV version 1.14