summaryrefslogtreecommitdiff
path: root/source3/rpc_client
diff options
context:
space:
mode:
Diffstat (limited to 'source3/rpc_client')
-rw-r--r--source3/rpc_client/cli_svcctl.c76
1 files changed, 0 insertions, 76 deletions
diff --git a/source3/rpc_client/cli_svcctl.c b/source3/rpc_client/cli_svcctl.c
index 3c29dcdee8..51678083d3 100644
--- a/source3/rpc_client/cli_svcctl.c
+++ b/source3/rpc_client/cli_svcctl.c
@@ -90,79 +90,3 @@ WERROR rpccli_svcctl_enumerate_services( struct rpc_pipe_client *cli, TALLOC_CTX
return out.status;
}
-
-/*******************************************************************
-*******************************************************************/
-
-WERROR rpccli_svcctl_query_config(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx,
- POLICY_HND *hService, SERVICE_CONFIG *config )
-{
- SVCCTL_Q_QUERY_SERVICE_CONFIG in;
- SVCCTL_R_QUERY_SERVICE_CONFIG out;
- prs_struct qbuf, rbuf;
-
- ZERO_STRUCT(in);
- ZERO_STRUCT(out);
-
- memcpy( &in.handle, hService, sizeof(POLICY_HND) );
- in.buffer_size = 0;
-
-
- CLI_DO_RPC_WERR( cli, mem_ctx, &ndr_table_svcctl.syntax_id,
- SVCCTL_QUERY_SERVICE_CONFIG_W,
- in, out,
- qbuf, rbuf,
- svcctl_io_q_query_service_config,
- svcctl_io_r_query_service_config,
- WERR_GENERAL_FAILURE );
-
- if ( W_ERROR_EQUAL( out.status, WERR_INSUFFICIENT_BUFFER ) ) {
- in.buffer_size = out.needed;
-
- CLI_DO_RPC_WERR( cli, mem_ctx, &ndr_table_svcctl.syntax_id,
- SVCCTL_QUERY_SERVICE_CONFIG_W,
- in, out,
- qbuf, rbuf,
- svcctl_io_q_query_service_config,
- svcctl_io_r_query_service_config,
- WERR_GENERAL_FAILURE );
- }
-
- if ( !W_ERROR_IS_OK( out.status ) )
- return out.status;
-
- memcpy( config, &out.config, sizeof(SERVICE_CONFIG) );
-
- config->executablepath = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- config->loadordergroup = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- config->dependencies = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- config->startname = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- config->displayname = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
-
- if ( out.config.executablepath ) {
- config->executablepath = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- copy_unistr2( config->executablepath, out.config.executablepath );
- }
-
- if ( out.config.loadordergroup ) {
- config->loadordergroup = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- copy_unistr2( config->loadordergroup, out.config.loadordergroup );
- }
-
- if ( out.config.dependencies ) {
- config->dependencies = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- copy_unistr2( config->dependencies, out.config.dependencies );
- }
-
- if ( out.config.startname ) {
- config->startname = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- copy_unistr2( config->startname, out.config.startname );
- }
-
- if ( out.config.displayname ) {
- config->displayname = TALLOC_ZERO_P( mem_ctx, UNISTR2 );
- copy_unistr2( config->displayname, out.config.displayname );
- }
-
- return out.status;
-}