Author: ekohl
Date: Sat Sep 29 09:06:42 2012
New Revision: 57422
URL:
http://svn.reactos.org/svn/reactos?rev=57422&view=rev
Log:
[FORMATTING]
- Fix indentation.
- Remove dead code.
No code changes!
Modified:
trunk/reactos/dll/win32/advapi32/misc/logon.c
trunk/reactos/dll/win32/advapi32/misc/shutdown.c
trunk/reactos/dll/win32/advapi32/reg/reg.c
Modified: trunk/reactos/dll/win32/advapi32/misc/logon.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/misc/lo…
==============================================================================
--- trunk/reactos/dll/win32/advapi32/misc/logon.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/advapi32/misc/logon.c [iso-8859-1] Sat Sep 29 09:06:42 2012
@@ -130,9 +130,18 @@
/*
* @unimplemented
*/
-BOOL WINAPI CreateProcessWithLogonW( LPCWSTR lpUsername, LPCWSTR lpDomain, LPCWSTR
lpPassword, DWORD dwLogonFlags,
- LPCWSTR lpApplicationName, LPWSTR lpCommandLine, DWORD dwCreationFlags, LPVOID
lpEnvironment,
- LPCWSTR lpCurrentDirectory, LPSTARTUPINFOW lpStartupInfo, LPPROCESS_INFORMATION
lpProcessInformation )
+BOOL WINAPI
+CreateProcessWithLogonW(LPCWSTR lpUsername,
+ LPCWSTR lpDomain,
+ LPCWSTR lpPassword,
+ DWORD dwLogonFlags,
+ LPCWSTR lpApplicationName,
+ LPWSTR lpCommandLine,
+ DWORD dwCreationFlags,
+ LPVOID lpEnvironment,
+ LPCWSTR lpCurrentDirectory,
+ LPSTARTUPINFOW lpStartupInfo,
+ LPPROCESS_INFORMATION lpProcessInformation)
{
FIXME("%s %s %s 0x%08x %s %s 0x%08x %p %s %p %p stub\n",
debugstr_w(lpUsername), debugstr_w(lpDomain),
debugstr_w(lpPassword), dwLogonFlags, debugstr_w(lpApplicationName),
@@ -301,98 +310,6 @@
GetUserSid(LPCWSTR UserName,
PSID *Sid)
{
-#if 0
- PSID lpSid;
- DWORD dwLength;
- HKEY hUsersKey;
- HKEY hUserKey;
-
- if (Sid != NULL)
- *Sid = NULL;
-
- /* Open the Users key */
- if (RegOpenKeyExW(HKEY_LOCAL_MACHINE,
- L"SAM\\SAM\\Domains\\Account\\Users",
- 0,
- KEY_READ,
- &hUsersKey))
- {
- ERR("Failed to open Users key! (Error %lu)\n", GetLastError());
- return FALSE;
- }
-
- /* Open the user key */
- if (RegOpenKeyExW(hUsersKey,
- UserName,
- 0,
- KEY_READ,
- &hUserKey))
- {
- if (GetLastError() == ERROR_FILE_NOT_FOUND)
- {
- ERR("Invalid user name!\n");
- SetLastError(ERROR_NO_SUCH_USER);
- }
- else
- {
- ERR("Failed to open user key! (Error %lu)\n", GetLastError());
- }
-
- RegCloseKey(hUsersKey);
- return FALSE;
- }
-
- RegCloseKey (hUsersKey);
-
- /* Get SID size */
- dwLength = 0;
- if (RegQueryValueExW(hUserKey,
- L"Sid",
- NULL,
- NULL,
- NULL,
- &dwLength))
- {
- ERR("Failed to read the SID size! (Error %lu)\n", GetLastError());
- RegCloseKey(hUserKey);
- return FALSE;
- }
-
- /* Allocate sid buffer */
- TRACE("Required SID buffer size: %lu\n", dwLength);
- lpSid = (PSID)RtlAllocateHeap(RtlGetProcessHeap(),
- 0,
- dwLength);
- if (lpSid == NULL)
- {
- ERR("Failed to allocate SID buffer!\n");
- RegCloseKey(hUserKey);
- return FALSE;
- }
-
- /* Read sid */
- if (RegQueryValueExW(hUserKey,
- L"Sid",
- NULL,
- NULL,
- (LPBYTE)lpSid,
- &dwLength))
- {
- ERR("Failed to read the SID! (Error %lu)\n", GetLastError());
- RtlFreeHeap(RtlGetProcessHeap(),
- 0,
- lpSid);
- RegCloseKey(hUserKey);
- return FALSE;
- }
-
- RegCloseKey(hUserKey);
-
- *Sid = lpSid;
-
- return TRUE;
-#endif
-
PSID AccountDomainSid = NULL;
ULONG ulUserRid;
DWORD dwLength;
Modified: trunk/reactos/dll/win32/advapi32/misc/shutdown.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/misc/sh…
==============================================================================
--- trunk/reactos/dll/win32/advapi32/misc/shutdown.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/advapi32/misc/shutdown.c [iso-8859-1] Sat Sep 29 09:06:42
2012
@@ -3,7 +3,7 @@
* PROJECT: ReactOS system libraries
* FILE: dll/win32/advapi32/misc/shutdown.c
* PURPOSE: System shutdown functions
- * PROGRAMMER: Lee Schroeder <spaceseel at gmail dot com>
+ * PROGRAMMER: Lee Schroeder <spaceseel at gmail dot com>
* Emanuele Aliberti
*/
@@ -64,7 +64,7 @@
BOOL bForceAppsClosed,
BOOL bRebootAfterShutdown)
{
- return InitiateSystemShutdownExW(lpMachineName,
+ return InitiateSystemShutdownExW(lpMachineName,
lpMessage,
dwTimeout,
bForceAppsClosed,
@@ -87,7 +87,7 @@
BOOL bForceAppsClosed,
BOOL bRebootAfterShutdown)
{
- return InitiateSystemShutdownExA(lpMachineName,
+ return InitiateSystemShutdownExA(lpMachineName,
lpMessage,
dwTimeout,
bForceAppsClosed,
@@ -178,7 +178,7 @@
return FALSE;
}
}
-
+
rv = InitiateSystemShutdownExW(MachineNameW.Buffer,
MessageW.Buffer,
dwTimeout,
Modified: trunk/reactos/dll/win32/advapi32/reg/reg.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/reg/reg…
==============================================================================
--- trunk/reactos/dll/win32/advapi32/reg/reg.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/advapi32/reg/reg.c [iso-8859-1] Sat Sep 29 09:06:42 2012
@@ -931,7 +931,7 @@
LocalObjectAttributes.ObjectName = &LocalKeyName;
FullNameLength = LocalKeyName.Length / sizeof(WCHAR);
- LocalKeyHandle = NULL;
+ LocalKeyHandle = NULL;
/* Remove the last part of the key name and try to create the key again. */
while (Status == STATUS_OBJECT_NAME_NOT_FOUND)