Author: ekohl
Date: Sun Nov 13 00:13:00 2011
New Revision: 54370
URL: http://svn.reactos.org/svn/reactos?rev=54370&view=rev
Log:
[SERVICES]
RControlService: Initialize the callers service status information.
Modified:
trunk/reactos/base/system/services/rpcserver.c
Modified: trunk/reactos/base/system/services/rpcserver.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/base/system/services/rpcse…
==============================================================================
--- trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] (original)
+++ trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] Sun Nov 13 00:13:00 2011
@@ -1095,7 +1095,6 @@
return ERROR_INVALID_HANDLE;
}
-
/* Check the service entry point */
lpService = hSvc->ServiceEntry;
if (lpService == NULL)
@@ -1131,6 +1130,11 @@
if (!RtlAreAllAccessesGranted(hSvc->Handle.DesiredAccess,
DesiredAccess))
return ERROR_ACCESS_DENIED;
+
+ /* Return the current service status information */
+ RtlCopyMemory(lpServiceStatus,
+ &lpService->Status,
+ sizeof(SERVICE_STATUS));
if (dwControl == SERVICE_CONTROL_STOP)
{
Author: ekohl
Date: Sat Nov 12 21:16:20 2011
New Revision: 54369
URL: http://svn.reactos.org/svn/reactos?rev=54369&view=rev
Log:
[SERVICES]
RControlService returns ERROR_SERVICE_NOT_ACTIVE if the service has not been started.
Modified:
trunk/reactos/base/system/services/rpcserver.c
Modified: trunk/reactos/base/system/services/rpcserver.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/base/system/services/rpcse…
==============================================================================
--- trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] (original)
+++ trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] Sat Nov 12 21:16:20 2011
@@ -646,6 +646,7 @@
return ERROR_INVALID_PARAMETER;
}
+
DWORD
ScmCanonDriverImagePath(DWORD dwStartType,
const wchar_t *lpServiceName,
@@ -1178,6 +1179,10 @@
{
dwControlsAccepted = lpService->Status.dwControlsAccepted;
dwCurrentState = lpService->Status.dwCurrentState;
+
+ /* Return ERROR_SERVICE_NOT_ACTIVE if the service has not been started */
+ if (lpService->lpImage == NULL || dwCurrentState == SERVICE_STOPPED)
+ return ERROR_SERVICE_NOT_ACTIVE;
/* Check the current state before sending a control request */
switch (dwCurrentState)
@@ -2064,9 +2069,10 @@
/* Unlock the service database */
ScmUnlockDatabase();
- /* check if it is marked for deletion */
+ /* Check if it is marked for deletion */
if (lpService->bDeleted)
return ERROR_SERVICE_MARKED_FOR_DELETE;
+
/* Return Error exist */
return ERROR_SERVICE_EXISTS;
}
Author: tfaber
Date: Sat Nov 12 14:49:14 2011
New Revision: 54363
URL: http://svn.reactos.org/svn/reactos?rev=54363&view=rev
Log:
[KMTESTS/KE]
- Do not check IRQLs above HIGH_LEVEL. That's not very useful anyway. Fixes hang in kmtest:KeIrql.
Modified:
trunk/rostests/kmtests/ntos_ke/KeIrql.c
Modified: trunk/rostests/kmtests/ntos_ke/KeIrql.c
URL: http://svn.reactos.org/svn/reactos/trunk/rostests/kmtests/ntos_ke/KeIrql.c?…
==============================================================================
--- trunk/rostests/kmtests/ntos_ke/KeIrql.c [iso-8859-1] (original)
+++ trunk/rostests/kmtests/ntos_ke/KeIrql.c [iso-8859-1] Sat Nov 12 14:49:14 2011
@@ -92,21 +92,6 @@
--Irql;
}
- DPRINT("Alive!\n");
- /* on x86, you can raise to _any_ possible KIRQL value */
- /* on x64, anything with more than the least significant 4 bits set bugchecked, last time I tried */
- /* TODO: other platforms? */
-#if defined _M_IX86
- for (Irql = PASSIVE_LEVEL; Irql <= (KIRQL)-1; ++Irql)
- {
- DPRINT("Raising to %u\n", Irql);
- KeRaiseIrql(Irql, &Irql2);
- ok_eq_uint(Irql2, PrevIrql);
- KeLowerIrql(Irql2);
- ok_irql(PrevIrql);
- }
-#endif /* defined _M_IX86 */
-
/* test KeRaiseIrqlToDpcLevel */
ok_irql(PASSIVE_LEVEL);
Irql = KeRaiseIrqlToDpcLevel();