summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-02-19 02:41:05 +0100
committerGünther Deschner <gd@samba.org>2008-02-19 03:13:10 +0100
commit4421e0d1470b82cdf7988a6c6d2ac67c8ea6c753 (patch)
tree55682c9be93cbcd8f9bf1b709d0eeec6349b0aaf
parent35e48a4b1dfa3d63476fca105766da1ec980b446 (diff)
downloadsamba-4421e0d1470b82cdf7988a6c6d2ac67c8ea6c753.tar.gz
samba-4421e0d1470b82cdf7988a6c6d2ac67c8ea6c753.tar.bz2
samba-4421e0d1470b82cdf7988a6c6d2ac67c8ea6c753.zip
Use pidl for _svcctl_QueryServiceStatus().
Guenther (This used to be commit 5453d97ef4967755ef0c903dd665325d50845028)
-rw-r--r--source3/rpc_server/srv_svcctl.c18
-rw-r--r--source3/rpc_server/srv_svcctl_nt.c14
2 files changed, 6 insertions, 26 deletions
diff --git a/source3/rpc_server/srv_svcctl.c b/source3/rpc_server/srv_svcctl.c
index dd3a42235d..3b9960c647 100644
--- a/source3/rpc_server/srv_svcctl.c
+++ b/source3/rpc_server/srv_svcctl.c
@@ -77,23 +77,7 @@ static bool api_svcctl_get_display_name(pipes_struct *p)
static bool api_svcctl_query_status(pipes_struct *p)
{
- SVCCTL_Q_QUERY_STATUS q_u;
- SVCCTL_R_QUERY_STATUS r_u;
- prs_struct *data = &p->in_data.data;
- prs_struct *rdata = &p->out_data.rdata;
-
- ZERO_STRUCT(q_u);
- ZERO_STRUCT(r_u);
-
- if(!svcctl_io_q_query_status("", &q_u, data, 0))
- return False;
-
- r_u.status = _svcctl_query_status(p, &q_u, &r_u);
-
- if(!svcctl_io_r_query_status("", &r_u, rdata, 0))
- return False;
-
- return True;
+ return proxy_svcctl_call(p, NDR_SVCCTL_QUERYSERVICESTATUS);
}
/*******************************************************************
diff --git a/source3/rpc_server/srv_svcctl_nt.c b/source3/rpc_server/srv_svcctl_nt.c
index e8969c70ac..9baf2d5110 100644
--- a/source3/rpc_server/srv_svcctl_nt.c
+++ b/source3/rpc_server/srv_svcctl_nt.c
@@ -361,11 +361,13 @@ WERROR _svcctl_GetServiceDisplayNameW(pipes_struct *p,
}
/********************************************************************
+ _svcctl_QueryServiceStatus
********************************************************************/
-WERROR _svcctl_query_status(pipes_struct *p, SVCCTL_Q_QUERY_STATUS *q_u, SVCCTL_R_QUERY_STATUS *r_u)
+WERROR _svcctl_QueryServiceStatus(pipes_struct *p,
+ struct svcctl_QueryServiceStatus *r)
{
- SERVICE_INFO *info = find_service_info_by_hnd( p, &q_u->handle );
+ SERVICE_INFO *info = find_service_info_by_hnd( p, r->in.handle );
/* perform access checks */
@@ -377,7 +379,7 @@ WERROR _svcctl_query_status(pipes_struct *p, SVCCTL_Q_QUERY_STATUS *q_u, SVCCTL_
/* try the service specific status call */
- return info->ops->service_status( info->name, &r_u->svc_status );
+ return info->ops->service_status( info->name, r->out.service_status );
}
/********************************************************************
@@ -916,12 +918,6 @@ WERROR _svcctl_SetServiceObjectSecurity(pipes_struct *p, struct svcctl_SetServic
return WERR_NOT_SUPPORTED;
}
-WERROR _svcctl_QueryServiceStatus(pipes_struct *p, struct svcctl_QueryServiceStatus *r)
-{
- p->rng_fault_state = True;
- return WERR_NOT_SUPPORTED;
-}
-
WERROR _svcctl_SetServiceStatus(pipes_struct *p, struct svcctl_SetServiceStatus *r)
{
p->rng_fault_state = True;