From 76da89daaadc358c836817cf597a1ff1489a9029 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Thu, 9 Apr 2009 15:39:45 +0200 Subject: s3-svcctl: minor fix for _svcctl_EnumDependentServicesW(). Guenther --- source3/rpc_server/srv_svcctl_nt.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'source3/rpc_server') diff --git a/source3/rpc_server/srv_svcctl_nt.c b/source3/rpc_server/srv_svcctl_nt.c index 350a5ca236..0b0ef83bee 100644 --- a/source3/rpc_server/srv_svcctl_nt.c +++ b/source3/rpc_server/srv_svcctl_nt.c @@ -546,6 +546,15 @@ WERROR _svcctl_EnumDependentServicesW(pipes_struct *p, if ( !(info->access_granted & SC_RIGHT_SVC_ENUMERATE_DEPENDENTS) ) return WERR_ACCESS_DENIED; + switch (r->in.state) { + case SERVICE_STATE_ACTIVE: + case SERVICE_STATE_INACTIVE: + case SERVICE_STATE_ALL: + break; + default: + return WERR_INVALID_PARAM; + } + /* we have to set the outgoing buffer size to the same as the incoming buffer size (even in the case of failure */ /* this is done in the autogenerated server already - gd */ -- cgit