-/* $Id: shutdown.c,v 1.11 2004/01/20 01:40:18 ekohl Exp $
+/* $Id$
*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS system libraries
* 19990515 EA
*/
-#include <windows.h>
-
-#define NTOS_MODE_USER
-#include <ntos.h>
+#include <advapi32.h>
+#include <wine/debug.h>
#define USZ {0,0,0}
return FALSE;
}
rv = AbortSystemShutdownW(MachineNameW.Buffer);
- RtlFreeAnsiString(&MachineNameA);
RtlFreeUnicodeString(&MachineNameW);
SetLastError(ERROR_SUCCESS);
return rv;
RtlInitAnsiString(&MachineNameA, lpMachineName);
Status = RtlAnsiStringToUnicodeString(&MachineNameW, &MachineNameA, TRUE);
if (STATUS_SUCCESS != Status) {
- RtlFreeAnsiString(&MachineNameA);
SetLastError(RtlNtStatusToDosError(Status));
return FALSE;
}
Status = RtlAnsiStringToUnicodeString(&MessageW, &MessageA, TRUE);
if (STATUS_SUCCESS != Status) {
if (MachineNameW.Length) {
- RtlFreeAnsiString(&MachineNameA);
RtlFreeUnicodeString(&MachineNameW);
}
- RtlFreeAnsiString(&MessageA);
SetLastError(RtlNtStatusToDosError(Status));
return FALSE;
}
bRebootAfterShutdown);
LastError = GetLastError();
if (lpMachineName) {
- RtlFreeAnsiString(&MachineNameA);
RtlFreeUnicodeString(&MachineNameW);
}
if (lpMessage) {
- RtlFreeAnsiString(&MessageA);
RtlFreeUnicodeString(&MessageW);
}
SetLastError(LastError);
return rv;
}
+/******************************************************************************
+ * InitiateSystemShutdownExW [ADVAPI32.@]
+ *
+ * see InitiateSystemShutdownExA
+ */
+BOOL WINAPI InitiateSystemShutdownExW( LPWSTR lpMachineName, LPWSTR lpMessage,
+ DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown,
+ DWORD dwReason)
+{
+ FIXME("%s %s %ld %d %d %ld\n", debugstr_w(lpMachineName),
+ debugstr_w(lpMessage), dwTimeout, bForceAppsClosed,
+ bRebootAfterShutdown, dwReason);
+ return TRUE;
+}
+
/* EOF */