mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 10:22:59 +00:00
[USERENV]
Fix coding style and indentation. No code changes! svn path=/trunk/; revision=60744
This commit is contained in:
parent
5bb77216c8
commit
480ce3de05
11 changed files with 1254 additions and 1213 deletions
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/desktop.c
|
||||
* FILE: dll/win32/userenv/desktop.c
|
||||
* PURPOSE: Desktop and start menu support functions.
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -32,8 +32,9 @@
|
|||
|
||||
/* FUNCTIONS ***************************************************************/
|
||||
|
||||
static BOOL
|
||||
GetDesktopPath (BOOL bCommonPath,
|
||||
static
|
||||
BOOL
|
||||
GetDesktopPath(BOOL bCommonPath,
|
||||
LPWSTR lpDesktopPath)
|
||||
{
|
||||
WCHAR szPath[MAX_PATH];
|
||||
|
@ -42,22 +43,22 @@ GetDesktopPath (BOOL bCommonPath,
|
|||
HKEY hKey;
|
||||
LONG Error;
|
||||
|
||||
DPRINT ("GetDesktopPath() called\n");
|
||||
DPRINT("GetDesktopPath() called\n");
|
||||
|
||||
Error = RegOpenKeyExW (HKEY_CURRENT_USER,
|
||||
Error = RegOpenKeyExW(HKEY_CURRENT_USER,
|
||||
L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\User Shell Folders",
|
||||
0,
|
||||
KEY_QUERY_VALUE,
|
||||
&hKey);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("RegOpenKeyExW() failed\n");
|
||||
DPRINT1("RegOpenKeyExW() failed\n");
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
dwLength = MAX_PATH * sizeof(WCHAR);
|
||||
Error = RegQueryValueExW (hKey,
|
||||
Error = RegQueryValueExW(hKey,
|
||||
bCommonPath ? L"Common Desktop" : L"Desktop",
|
||||
0,
|
||||
&dwType,
|
||||
|
@ -65,33 +66,34 @@ GetDesktopPath (BOOL bCommonPath,
|
|||
&dwLength);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("RegQueryValueExW() failed\n");
|
||||
RegCloseKey (hKey);
|
||||
DPRINT1("RegQueryValueExW() failed\n");
|
||||
RegCloseKey(hKey);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
RegCloseKey (hKey);
|
||||
RegCloseKey(hKey);
|
||||
|
||||
if (dwType == REG_EXPAND_SZ)
|
||||
{
|
||||
ExpandEnvironmentStringsW (szPath,
|
||||
ExpandEnvironmentStringsW(szPath,
|
||||
lpDesktopPath,
|
||||
MAX_PATH);
|
||||
}
|
||||
else
|
||||
{
|
||||
wcscpy (lpDesktopPath, szPath);
|
||||
wcscpy(lpDesktopPath, szPath);
|
||||
}
|
||||
|
||||
DPRINT ("GetDesktopPath() done\n");
|
||||
DPRINT("GetDesktopPath() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
static BOOL
|
||||
GetProgramsPath (BOOL bCommonPath,
|
||||
static
|
||||
BOOL
|
||||
GetProgramsPath(BOOL bCommonPath,
|
||||
LPWSTR lpProgramsPath)
|
||||
{
|
||||
WCHAR szPath[MAX_PATH];
|
||||
|
@ -100,22 +102,22 @@ GetProgramsPath (BOOL bCommonPath,
|
|||
HKEY hKey;
|
||||
LONG Error;
|
||||
|
||||
DPRINT ("GetProgramsPath() called\n");
|
||||
DPRINT("GetProgramsPath() called\n");
|
||||
|
||||
Error = RegOpenKeyExW (HKEY_CURRENT_USER,
|
||||
Error = RegOpenKeyExW(HKEY_CURRENT_USER,
|
||||
L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\User Shell Folders",
|
||||
0,
|
||||
KEY_QUERY_VALUE,
|
||||
&hKey);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("RegOpenKeyExW() failed\n");
|
||||
DPRINT1("RegOpenKeyExW() failed\n");
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
dwLength = MAX_PATH * sizeof(WCHAR);
|
||||
Error = RegQueryValueExW (hKey,
|
||||
Error = RegQueryValueExW(hKey,
|
||||
bCommonPath ? L"Common Programs" : L"Programs",
|
||||
0,
|
||||
&dwType,
|
||||
|
@ -123,34 +125,35 @@ GetProgramsPath (BOOL bCommonPath,
|
|||
&dwLength);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("RegQueryValueExW() failed\n");
|
||||
RegCloseKey (hKey);
|
||||
DPRINT1("RegQueryValueExW() failed\n");
|
||||
RegCloseKey(hKey);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
RegCloseKey (hKey);
|
||||
RegCloseKey(hKey);
|
||||
|
||||
if (dwType == REG_EXPAND_SZ)
|
||||
{
|
||||
ExpandEnvironmentStringsW (szPath,
|
||||
ExpandEnvironmentStringsW(szPath,
|
||||
lpProgramsPath,
|
||||
MAX_PATH);
|
||||
}
|
||||
else
|
||||
{
|
||||
wcscpy (lpProgramsPath,
|
||||
wcscpy(lpProgramsPath,
|
||||
szPath);
|
||||
}
|
||||
|
||||
DPRINT ("GetProgramsPath() done\n");
|
||||
DPRINT("GetProgramsPath() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
AddDesktopItemA (BOOL bCommonItem,
|
||||
BOOL
|
||||
WINAPI
|
||||
AddDesktopItemA(BOOL bCommonItem,
|
||||
LPCSTR lpItemName,
|
||||
LPCSTR lpArguments,
|
||||
LPCSTR lpIconLocation,
|
||||
|
@ -224,8 +227,9 @@ AddDesktopItemA (BOOL bCommonItem,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
AddDesktopItemW (BOOL bCommonDesktop,
|
||||
BOOL
|
||||
WINAPI
|
||||
AddDesktopItemW(BOOL bCommonDesktop,
|
||||
LPCWSTR lpItemName,
|
||||
LPCWSTR lpArguments,
|
||||
LPCWSTR lpIconLocation,
|
||||
|
@ -247,59 +251,59 @@ AddDesktopItemW (BOOL bCommonDesktop,
|
|||
HRESULT hr;
|
||||
BOOL bResult;
|
||||
|
||||
DPRINT ("AddDesktopItemW() called\n");
|
||||
DPRINT("AddDesktopItemW() called\n");
|
||||
|
||||
bResult = FALSE;
|
||||
|
||||
if (!GetDesktopPath (bCommonDesktop, szLinkPath))
|
||||
if (!GetDesktopPath(bCommonDesktop, szLinkPath))
|
||||
{
|
||||
DPRINT1 ("GetDesktopPath() failed\n");
|
||||
DPRINT1("GetDesktopPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
DPRINT ("Desktop path: '%S'\n", szLinkPath);
|
||||
DPRINT("Desktop path: '%S'\n", szLinkPath);
|
||||
|
||||
/* Make sure the path exists */
|
||||
hFind = FindFirstFileW (szLinkPath,
|
||||
hFind = FindFirstFileW(szLinkPath,
|
||||
&FindData);
|
||||
if (hFind == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
DPRINT ("'%S' does not exist\n", szLinkPath);
|
||||
DPRINT("'%S' does not exist\n", szLinkPath);
|
||||
|
||||
/* Create directory path */
|
||||
if (!CreateDirectoryPath (szLinkPath, NULL))
|
||||
if (!CreateDirectoryPath(szLinkPath, NULL))
|
||||
return FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
DPRINT ("'%S' exists\n", szLinkPath);
|
||||
FindClose (hFind);
|
||||
DPRINT("'%S' exists\n", szLinkPath);
|
||||
FindClose(hFind);
|
||||
}
|
||||
|
||||
/* Append backslash, item name and ".lnk" extension */
|
||||
wcscat (szLinkPath, L"\\");
|
||||
wcscat (szLinkPath, lpItemName);
|
||||
wcscat (szLinkPath, L".lnk");
|
||||
DPRINT ("Link path: '%S'\n", szLinkPath);
|
||||
wcscat(szLinkPath, L"\\");
|
||||
wcscat(szLinkPath, lpItemName);
|
||||
wcscat(szLinkPath, L".lnk");
|
||||
DPRINT("Link path: '%S'\n", szLinkPath);
|
||||
|
||||
/* Split 'lpArguments' string into command and arguments */
|
||||
Ptr = wcschr (lpArguments, L' ');
|
||||
DPRINT ("Ptr %p lpArguments %p\n", Ptr, lpArguments);
|
||||
Ptr = wcschr(lpArguments, L' ');
|
||||
DPRINT("Ptr %p lpArguments %p\n", Ptr, lpArguments);
|
||||
if (Ptr != NULL)
|
||||
{
|
||||
dwLength = (DWORD)(Ptr - lpArguments);
|
||||
DPRINT ("dwLength %lu\n", dwLength);
|
||||
memcpy (szCommand, lpArguments, dwLength * sizeof(WCHAR));
|
||||
DPRINT("dwLength %lu\n", dwLength);
|
||||
memcpy(szCommand, lpArguments, dwLength * sizeof(WCHAR));
|
||||
szCommand[dwLength] = 0;
|
||||
Ptr++;
|
||||
wcscpy (szArguments, Ptr);
|
||||
wcscpy(szArguments, Ptr);
|
||||
}
|
||||
else
|
||||
{
|
||||
wcscpy (szCommand, lpArguments);
|
||||
wcscpy(szCommand, lpArguments);
|
||||
szArguments[0] = 0;
|
||||
}
|
||||
DPRINT ("szCommand: '%S'\n", szCommand);
|
||||
DPRINT ("szArguments: '%S'\n", szArguments);
|
||||
DPRINT("szCommand: '%S'\n", szCommand);
|
||||
DPRINT("szArguments: '%S'\n", szArguments);
|
||||
|
||||
/* Dynamically load ole32.dll */
|
||||
if (!LoadDynamicImports(&DynOle32, &Ole32))
|
||||
|
@ -372,14 +376,15 @@ AddDesktopItemW (BOOL bCommonDesktop,
|
|||
|
||||
UnloadDynamicImports(&Ole32);
|
||||
|
||||
DPRINT ("AddDesktopItemW() done\n");
|
||||
DPRINT("AddDesktopItemW() done\n");
|
||||
|
||||
return bResult;
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteDesktopItemA (BOOL bCommonItem,
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteDesktopItemA(BOOL bCommonItem,
|
||||
LPCSTR lpItemName)
|
||||
{
|
||||
UNICODE_STRING ItemName;
|
||||
|
@ -401,31 +406,33 @@ DeleteDesktopItemA (BOOL bCommonItem,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteDesktopItemW (BOOL bCommonItem,
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteDesktopItemW(BOOL bCommonItem,
|
||||
LPCWSTR lpItemName)
|
||||
{
|
||||
WCHAR szLinkPath[MAX_PATH];
|
||||
|
||||
DPRINT ("DeleteDesktopItemW() called\n");
|
||||
DPRINT("DeleteDesktopItemW() called\n");
|
||||
|
||||
if (!GetDesktopPath (bCommonItem, szLinkPath))
|
||||
if (!GetDesktopPath(bCommonItem, szLinkPath))
|
||||
{
|
||||
DPRINT1 ("GetDesktopPath() failed\n");
|
||||
DPRINT1("GetDesktopPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
wcscat (szLinkPath, L"\\");
|
||||
wcscat (szLinkPath, lpItemName);
|
||||
wcscat (szLinkPath, L".lnk");
|
||||
DPRINT ("Link path: '%S'\n", szLinkPath);
|
||||
wcscat(szLinkPath, L"\\");
|
||||
wcscat(szLinkPath, lpItemName);
|
||||
wcscat(szLinkPath, L".lnk");
|
||||
DPRINT("Link path: '%S'\n", szLinkPath);
|
||||
|
||||
return DeleteFileW (szLinkPath);
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
CreateGroupA (LPCSTR lpGroupName,
|
||||
BOOL
|
||||
WINAPI
|
||||
CreateGroupA(LPCSTR lpGroupName,
|
||||
BOOL bCommonGroup)
|
||||
{
|
||||
UNICODE_STRING GroupName;
|
||||
|
@ -446,27 +453,28 @@ CreateGroupA (LPCSTR lpGroupName,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
CreateGroupW (LPCWSTR lpGroupName,
|
||||
BOOL
|
||||
WINAPI
|
||||
CreateGroupW(LPCWSTR lpGroupName,
|
||||
BOOL bCommonGroup)
|
||||
{
|
||||
WCHAR szGroupPath[MAX_PATH];
|
||||
|
||||
DPRINT1 ("CreateGroupW() called\n");
|
||||
DPRINT1("CreateGroupW() called\n");
|
||||
|
||||
if (lpGroupName == NULL || *lpGroupName == 0)
|
||||
return TRUE;
|
||||
|
||||
if (!GetProgramsPath (bCommonGroup, szGroupPath))
|
||||
if (!GetProgramsPath(bCommonGroup, szGroupPath))
|
||||
{
|
||||
DPRINT1 ("GetProgramsPath() failed\n");
|
||||
DPRINT1("GetProgramsPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
DPRINT1 ("Programs path: '%S'\n", szGroupPath);
|
||||
DPRINT1("Programs path: '%S'\n", szGroupPath);
|
||||
|
||||
wcscat (szGroupPath, L"\\");
|
||||
wcscat (szGroupPath, lpGroupName);
|
||||
DPRINT1 ("Group path: '%S'\n", szGroupPath);
|
||||
wcscat(szGroupPath, L"\\");
|
||||
wcscat(szGroupPath, lpGroupName);
|
||||
DPRINT1("Group path: '%S'\n", szGroupPath);
|
||||
|
||||
/* Create directory path */
|
||||
if (!CreateDirectoryPath (szGroupPath, NULL))
|
||||
|
@ -474,14 +482,15 @@ CreateGroupW (LPCWSTR lpGroupName,
|
|||
|
||||
/* FIXME: Notify the shell */
|
||||
|
||||
DPRINT1 ("CreateGroupW() done\n");
|
||||
DPRINT1("CreateGroupW() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteGroupA (LPCSTR lpGroupName,
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteGroupA(LPCSTR lpGroupName,
|
||||
BOOL bCommonGroup)
|
||||
{
|
||||
UNICODE_STRING GroupName;
|
||||
|
@ -502,27 +511,28 @@ DeleteGroupA (LPCSTR lpGroupName,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteGroupW (LPCWSTR lpGroupName,
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteGroupW(LPCWSTR lpGroupName,
|
||||
BOOL bCommonGroup)
|
||||
{
|
||||
WCHAR szGroupPath[MAX_PATH];
|
||||
|
||||
DPRINT ("DeleteGroupW() called\n");
|
||||
DPRINT("DeleteGroupW() called\n");
|
||||
|
||||
if (lpGroupName == NULL || *lpGroupName == 0)
|
||||
return TRUE;
|
||||
|
||||
if (!GetProgramsPath (bCommonGroup, szGroupPath))
|
||||
if (!GetProgramsPath(bCommonGroup, szGroupPath))
|
||||
{
|
||||
DPRINT1 ("GetProgramsPath() failed\n");
|
||||
DPRINT1("GetProgramsPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
DPRINT ("Programs path: '%S'\n", szGroupPath);
|
||||
DPRINT("Programs path: '%S'\n", szGroupPath);
|
||||
|
||||
wcscat (szGroupPath, L"\\");
|
||||
wcscat (szGroupPath, lpGroupName);
|
||||
DPRINT ("Group path: '%S'\n", szGroupPath);
|
||||
wcscat(szGroupPath, L"\\");
|
||||
wcscat(szGroupPath, lpGroupName);
|
||||
DPRINT("Group path: '%S'\n", szGroupPath);
|
||||
|
||||
/* Remove directory path */
|
||||
if (!RemoveDirectoryPath (szGroupPath))
|
||||
|
@ -530,14 +540,15 @@ DeleteGroupW (LPCWSTR lpGroupName,
|
|||
|
||||
/* FIXME: Notify the shell */
|
||||
|
||||
DPRINT ("DeleteGroupW() done\n");
|
||||
DPRINT("DeleteGroupW() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
AddItemA (LPCSTR lpGroupName, /* Optional */
|
||||
BOOL
|
||||
WINAPI
|
||||
AddItemA(LPCSTR lpGroupName, /* Optional */
|
||||
BOOL bCommonGroup,
|
||||
LPCSTR lpItemName,
|
||||
LPCSTR lpArguments,
|
||||
|
@ -636,8 +647,9 @@ AddItemA (LPCSTR lpGroupName, /* Optional */
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
AddItemW (LPCWSTR lpGroupName, /* Optional */
|
||||
BOOL
|
||||
WINAPI
|
||||
AddItemW(LPCWSTR lpGroupName, /* Optional */
|
||||
BOOL bCommonGroup,
|
||||
LPCWSTR lpItemName,
|
||||
LPCWSTR lpArguments,
|
||||
|
@ -660,64 +672,64 @@ AddItemW (LPCWSTR lpGroupName, /* Optional */
|
|||
HRESULT hr;
|
||||
BOOL bResult;
|
||||
|
||||
DPRINT ("AddItemW() called\n");
|
||||
DPRINT("AddItemW() called\n");
|
||||
|
||||
bResult = FALSE;
|
||||
|
||||
if (!GetProgramsPath (bCommonGroup, szLinkPath))
|
||||
if (!GetProgramsPath(bCommonGroup, szLinkPath))
|
||||
{
|
||||
DPRINT1 ("GetProgramsPath() failed\n");
|
||||
DPRINT1("GetProgramsPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DPRINT ("Programs path: '%S'\n", szLinkPath);
|
||||
DPRINT("Programs path: '%S'\n", szLinkPath);
|
||||
|
||||
if (lpGroupName != NULL && *lpGroupName != 0)
|
||||
{
|
||||
wcscat (szLinkPath, L"\\");
|
||||
wcscat (szLinkPath, lpGroupName);
|
||||
wcscat(szLinkPath, L"\\");
|
||||
wcscat(szLinkPath, lpGroupName);
|
||||
|
||||
/* Make sure the path exists */
|
||||
hFind = FindFirstFileW (szLinkPath,
|
||||
hFind = FindFirstFileW(szLinkPath,
|
||||
&FindData);
|
||||
if (hFind == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
DPRINT ("'%S' does not exist\n", szLinkPath);
|
||||
if (!CreateGroupW (lpGroupName,
|
||||
DPRINT("'%S' does not exist\n", szLinkPath);
|
||||
if (!CreateGroupW(lpGroupName,
|
||||
bCommonGroup))
|
||||
return FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
DPRINT ("'%S' exists\n", szLinkPath);
|
||||
FindClose (hFind);
|
||||
DPRINT("'%S' exists\n", szLinkPath);
|
||||
FindClose(hFind);
|
||||
}
|
||||
}
|
||||
|
||||
wcscat (szLinkPath, L"\\");
|
||||
wcscat (szLinkPath, lpItemName);
|
||||
wcscat (szLinkPath, L".lnk");
|
||||
DPRINT ("Link path: '%S'\n", szLinkPath);
|
||||
wcscat(szLinkPath, L"\\");
|
||||
wcscat(szLinkPath, lpItemName);
|
||||
wcscat(szLinkPath, L".lnk");
|
||||
DPRINT("Link path: '%S'\n", szLinkPath);
|
||||
|
||||
/* Split 'lpArguments' string into command and arguments */
|
||||
Ptr = wcschr (lpArguments, L' ');
|
||||
DPRINT ("Ptr %p lpArguments %p\n", Ptr, lpArguments);
|
||||
Ptr = wcschr(lpArguments, L' ');
|
||||
DPRINT("Ptr %p lpArguments %p\n", Ptr, lpArguments);
|
||||
if (Ptr != NULL)
|
||||
{
|
||||
dwLength = (DWORD)(Ptr - lpArguments);
|
||||
DPRINT ("dwLength %lu\n", dwLength);
|
||||
memcpy (szCommand, lpArguments, dwLength * sizeof(WCHAR));
|
||||
DPRINT("dwLength %lu\n", dwLength);
|
||||
memcpy(szCommand, lpArguments, dwLength * sizeof(WCHAR));
|
||||
szCommand[dwLength] = 0;
|
||||
Ptr++;
|
||||
wcscpy (szArguments, Ptr);
|
||||
wcscpy(szArguments, Ptr);
|
||||
}
|
||||
else
|
||||
{
|
||||
wcscpy (szCommand, lpArguments);
|
||||
wcscpy(szCommand, lpArguments);
|
||||
szArguments[0] = 0;
|
||||
}
|
||||
DPRINT ("szCommand: '%S'\n", szCommand);
|
||||
DPRINT ("szArguments: '%S'\n", szArguments);
|
||||
DPRINT("szCommand: '%S'\n", szCommand);
|
||||
DPRINT("szArguments: '%S'\n", szArguments);
|
||||
|
||||
/* Dynamically load ole32.dll */
|
||||
if (!LoadDynamicImports(&DynOle32, &Ole32))
|
||||
|
@ -789,14 +801,15 @@ AddItemW (LPCWSTR lpGroupName, /* Optional */
|
|||
Ole32.fn.CoUninitialize();
|
||||
UnloadDynamicImports(&Ole32);
|
||||
|
||||
DPRINT ("AddItemW() done\n");
|
||||
DPRINT("AddItemW() done\n");
|
||||
|
||||
return bResult;
|
||||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteItemA (LPCSTR lpGroupName, /* Optional */
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteItemA(LPCSTR lpGroupName, /* Optional */
|
||||
BOOL bCommonGroup,
|
||||
LPCSTR lpItemName,
|
||||
BOOL bDeleteGroup)
|
||||
|
@ -842,8 +855,9 @@ DeleteItemA (LPCSTR lpGroupName, /* Optional */
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
DeleteItemW (LPCWSTR lpGroupName, /* Optional */
|
||||
BOOL
|
||||
WINAPI
|
||||
DeleteItemW(LPCWSTR lpGroupName, /* Optional */
|
||||
BOOL bCommonGroup,
|
||||
LPCWSTR lpItemName,
|
||||
BOOL bDeleteGroup)
|
||||
|
@ -851,46 +865,46 @@ DeleteItemW (LPCWSTR lpGroupName, /* Optional */
|
|||
WCHAR szItemPath[MAX_PATH];
|
||||
LPWSTR Ptr;
|
||||
|
||||
DPRINT ("DeleteItemW() called\n");
|
||||
DPRINT("DeleteItemW() called\n");
|
||||
|
||||
if (!GetProgramsPath (bCommonGroup, szItemPath))
|
||||
if (!GetProgramsPath(bCommonGroup, szItemPath))
|
||||
{
|
||||
DPRINT1 ("GetProgramsPath() failed\n");
|
||||
DPRINT1("GetProgramsPath() failed\n");
|
||||
return FALSE;
|
||||
}
|
||||
DPRINT ("Programs path: '%S'\n", szItemPath);
|
||||
DPRINT("Programs path: '%S'\n", szItemPath);
|
||||
|
||||
if (lpGroupName != NULL && *lpGroupName != 0)
|
||||
{
|
||||
wcscat (szItemPath, L"\\");
|
||||
wcscat (szItemPath, lpGroupName);
|
||||
wcscat(szItemPath, L"\\");
|
||||
wcscat(szItemPath, lpGroupName);
|
||||
}
|
||||
|
||||
wcscat (szItemPath, L"\\");
|
||||
wcscat (szItemPath, lpItemName);
|
||||
wcscat (szItemPath, L".lnk");
|
||||
DPRINT ("Item path: '%S'\n", szItemPath);
|
||||
wcscat(szItemPath, L"\\");
|
||||
wcscat(szItemPath, lpItemName);
|
||||
wcscat(szItemPath, L".lnk");
|
||||
DPRINT("Item path: '%S'\n", szItemPath);
|
||||
|
||||
if (!DeleteFileW (szItemPath))
|
||||
if (!DeleteFileW(szItemPath))
|
||||
return FALSE;
|
||||
|
||||
/* FIXME: Notify the shell */
|
||||
|
||||
if (bDeleteGroup)
|
||||
{
|
||||
Ptr = wcsrchr (szItemPath, L'\\');
|
||||
Ptr = wcsrchr(szItemPath, L'\\');
|
||||
if (Ptr == NULL)
|
||||
return TRUE;
|
||||
|
||||
*Ptr = 0;
|
||||
DPRINT ("Item path: '%S'\n", szItemPath);
|
||||
if (RemoveDirectoryW (szItemPath))
|
||||
DPRINT("Item path: '%S'\n", szItemPath);
|
||||
if (RemoveDirectoryW(szItemPath))
|
||||
{
|
||||
/* FIXME: Notify the shell */
|
||||
}
|
||||
}
|
||||
|
||||
DPRINT ("DeleteItemW() done\n");
|
||||
DPRINT("DeleteItemW() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/directory.c
|
||||
* FILE: dll/win32/userenv/directory.c
|
||||
* PURPOSE: User profile code
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -32,7 +32,8 @@
|
|||
|
||||
/* FUNCTIONS ***************************************************************/
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
CopyProfileDirectoryA(LPCSTR lpSourcePath,
|
||||
LPCSTR lpDestinationPath,
|
||||
DWORD dwFlags)
|
||||
|
@ -67,7 +68,8 @@ CopyProfileDirectoryA(LPCSTR lpSourcePath,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
CopyProfileDirectoryW(LPCWSTR lpSourcePath,
|
||||
LPCWSTR lpDestinationPath,
|
||||
DWORD dwFlags)
|
||||
|
@ -78,7 +80,7 @@ CopyProfileDirectoryW(LPCWSTR lpSourcePath,
|
|||
|
||||
|
||||
BOOL
|
||||
CopyDirectory (LPCWSTR lpDestinationPath,
|
||||
CopyDirectory(LPCWSTR lpDestinationPath,
|
||||
LPCWSTR lpSourcePath)
|
||||
{
|
||||
WCHAR szFileName[MAX_PATH];
|
||||
|
@ -89,110 +91,110 @@ CopyDirectory (LPCWSTR lpDestinationPath,
|
|||
LPWSTR lpDstPtr;
|
||||
HANDLE hFind;
|
||||
|
||||
DPRINT ("CopyDirectory (%S, %S) called\n",
|
||||
DPRINT("CopyDirectory (%S, %S) called\n",
|
||||
lpDestinationPath, lpSourcePath);
|
||||
|
||||
wcscpy (szFileName, lpSourcePath);
|
||||
wcscat (szFileName, L"\\*.*");
|
||||
wcscpy(szFileName, lpSourcePath);
|
||||
wcscat(szFileName, L"\\*.*");
|
||||
|
||||
hFind = FindFirstFileW (szFileName,
|
||||
hFind = FindFirstFileW(szFileName,
|
||||
&FindFileData);
|
||||
if (hFind == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
wcscpy (szFullSrcName, lpSourcePath);
|
||||
lpSrcPtr = AppendBackslash (szFullSrcName);
|
||||
wcscpy(szFullSrcName, lpSourcePath);
|
||||
lpSrcPtr = AppendBackslash(szFullSrcName);
|
||||
|
||||
wcscpy (szFullDstName, lpDestinationPath);
|
||||
lpDstPtr = AppendBackslash (szFullDstName);
|
||||
wcscpy(szFullDstName, lpDestinationPath);
|
||||
lpDstPtr = AppendBackslash(szFullDstName);
|
||||
|
||||
for (;;)
|
||||
{
|
||||
if (wcscmp (FindFileData.cFileName, L".") &&
|
||||
wcscmp (FindFileData.cFileName, L".."))
|
||||
if (wcscmp(FindFileData.cFileName, L".") &&
|
||||
wcscmp(FindFileData.cFileName, L".."))
|
||||
{
|
||||
wcscpy (lpSrcPtr, FindFileData.cFileName);
|
||||
wcscpy (lpDstPtr, FindFileData.cFileName);
|
||||
wcscpy(lpSrcPtr, FindFileData.cFileName);
|
||||
wcscpy(lpDstPtr, FindFileData.cFileName);
|
||||
|
||||
if (FindFileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
|
||||
{
|
||||
DPRINT ("Create directory: %S\n", szFullDstName);
|
||||
if (!CreateDirectoryExW (szFullSrcName, szFullDstName, NULL))
|
||||
DPRINT("Create directory: %S\n", szFullDstName);
|
||||
if (!CreateDirectoryExW(szFullSrcName, szFullDstName, NULL))
|
||||
{
|
||||
if (GetLastError () != ERROR_ALREADY_EXISTS)
|
||||
if (GetLastError() != ERROR_ALREADY_EXISTS)
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
|
||||
FindClose (hFind);
|
||||
FindClose(hFind);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
if (!CopyDirectory (szFullDstName, szFullSrcName))
|
||||
if (!CopyDirectory(szFullDstName, szFullSrcName))
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
|
||||
FindClose (hFind);
|
||||
FindClose(hFind);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DPRINT ("Copy file: %S -> %S\n", szFullSrcName, szFullDstName);
|
||||
if (!CopyFileW (szFullSrcName, szFullDstName, FALSE))
|
||||
DPRINT("Copy file: %S -> %S\n", szFullSrcName, szFullDstName);
|
||||
if (!CopyFileW(szFullSrcName, szFullDstName, FALSE))
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
|
||||
FindClose (hFind);
|
||||
FindClose(hFind);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!FindNextFileW (hFind, &FindFileData))
|
||||
if (!FindNextFileW(hFind, &FindFileData))
|
||||
{
|
||||
if (GetLastError () != ERROR_NO_MORE_FILES)
|
||||
if (GetLastError() != ERROR_NO_MORE_FILES)
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
FindClose (hFind);
|
||||
FindClose(hFind);
|
||||
|
||||
DPRINT ("CopyDirectory() done\n");
|
||||
DPRINT("CopyDirectory() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
BOOL
|
||||
CreateDirectoryPath (LPCWSTR lpPathName,
|
||||
CreateDirectoryPath(LPCWSTR lpPathName,
|
||||
LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
||||
{
|
||||
WCHAR szPath[MAX_PATH];
|
||||
LPWSTR Ptr;
|
||||
DWORD dwError;
|
||||
|
||||
DPRINT ("CreateDirectoryPath() called\n");
|
||||
DPRINT("CreateDirectoryPath() called\n");
|
||||
|
||||
if (lpPathName == NULL || *lpPathName == 0)
|
||||
return TRUE;
|
||||
|
||||
if (CreateDirectoryW (lpPathName,
|
||||
if (CreateDirectoryW(lpPathName,
|
||||
lpSecurityAttributes))
|
||||
return TRUE;
|
||||
|
||||
dwError = GetLastError ();
|
||||
dwError = GetLastError();
|
||||
if (dwError == ERROR_ALREADY_EXISTS)
|
||||
return TRUE;
|
||||
|
||||
wcscpy (szPath, lpPathName);
|
||||
wcscpy(szPath, lpPathName);
|
||||
|
||||
if (wcslen(szPath) > 3 && szPath[1] == ':' && szPath[2] == '\\')
|
||||
{
|
||||
|
@ -205,15 +207,15 @@ CreateDirectoryPath (LPCWSTR lpPathName,
|
|||
|
||||
while (Ptr != NULL)
|
||||
{
|
||||
Ptr = wcschr (Ptr, L'\\');
|
||||
Ptr = wcschr(Ptr, L'\\');
|
||||
if (Ptr != NULL)
|
||||
*Ptr = 0;
|
||||
|
||||
DPRINT ("CreateDirectory(%S)\n", szPath);
|
||||
if (!CreateDirectoryW (szPath,
|
||||
DPRINT("CreateDirectory(%S)\n", szPath);
|
||||
if (!CreateDirectoryW(szPath,
|
||||
lpSecurityAttributes))
|
||||
{
|
||||
dwError = GetLastError ();
|
||||
dwError = GetLastError();
|
||||
if (dwError != ERROR_ALREADY_EXISTS)
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -225,25 +227,26 @@ CreateDirectoryPath (LPCWSTR lpPathName,
|
|||
}
|
||||
}
|
||||
|
||||
DPRINT ("CreateDirectoryPath() done\n");
|
||||
DPRINT("CreateDirectoryPath() done\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
static BOOL
|
||||
RecursiveRemoveDir (LPCWSTR lpPath)
|
||||
static
|
||||
BOOL
|
||||
RecursiveRemoveDir(LPCWSTR lpPath)
|
||||
{
|
||||
WCHAR szPath[MAX_PATH];
|
||||
WIN32_FIND_DATAW FindData;
|
||||
HANDLE hFind;
|
||||
BOOL bResult;
|
||||
|
||||
wcscpy (szPath, lpPath);
|
||||
wcscat (szPath, L"\\*.*");
|
||||
DPRINT ("Search path: '%S'\n", szPath);
|
||||
wcscpy(szPath, lpPath);
|
||||
wcscat(szPath, L"\\*.*");
|
||||
DPRINT("Search path: '%S'\n", szPath);
|
||||
|
||||
hFind = FindFirstFileW (szPath,
|
||||
hFind = FindFirstFileW(szPath,
|
||||
&FindData);
|
||||
if (hFind == INVALID_HANDLE_VALUE)
|
||||
return FALSE;
|
||||
|
@ -251,19 +254,19 @@ RecursiveRemoveDir (LPCWSTR lpPath)
|
|||
bResult = TRUE;
|
||||
while (TRUE)
|
||||
{
|
||||
if (wcscmp (FindData.cFileName, L".") &&
|
||||
wcscmp (FindData.cFileName, L".."))
|
||||
if (wcscmp(FindData.cFileName, L".") &&
|
||||
wcscmp(FindData.cFileName, L".."))
|
||||
{
|
||||
wcscpy (szPath, lpPath);
|
||||
wcscat (szPath, L"\\");
|
||||
wcscat (szPath, FindData.cFileName);
|
||||
DPRINT ("File name: '%S'\n", szPath);
|
||||
wcscpy(szPath, lpPath);
|
||||
wcscat(szPath, L"\\");
|
||||
wcscat(szPath, FindData.cFileName);
|
||||
DPRINT("File name: '%S'\n", szPath);
|
||||
|
||||
if (FindData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
|
||||
{
|
||||
DPRINT ("Delete directory: '%S'\n", szPath);
|
||||
DPRINT("Delete directory: '%S'\n", szPath);
|
||||
|
||||
if (!RecursiveRemoveDir (szPath))
|
||||
if (!RecursiveRemoveDir(szPath))
|
||||
{
|
||||
bResult = FALSE;
|
||||
break;
|
||||
|
@ -271,11 +274,11 @@ RecursiveRemoveDir (LPCWSTR lpPath)
|
|||
|
||||
if (FindData.dwFileAttributes & FILE_ATTRIBUTE_READONLY)
|
||||
{
|
||||
SetFileAttributesW (szPath,
|
||||
SetFileAttributesW(szPath,
|
||||
FindData.dwFileAttributes & ~FILE_ATTRIBUTE_READONLY);
|
||||
}
|
||||
|
||||
if (!RemoveDirectoryW (szPath))
|
||||
if (!RemoveDirectoryW(szPath))
|
||||
{
|
||||
bResult = FALSE;
|
||||
break;
|
||||
|
@ -283,15 +286,15 @@ RecursiveRemoveDir (LPCWSTR lpPath)
|
|||
}
|
||||
else
|
||||
{
|
||||
DPRINT ("Delete file: '%S'\n", szPath);
|
||||
DPRINT("Delete file: '%S'\n", szPath);
|
||||
|
||||
if (FindData.dwFileAttributes & (FILE_ATTRIBUTE_READONLY | FILE_ATTRIBUTE_SYSTEM))
|
||||
{
|
||||
SetFileAttributesW (szPath,
|
||||
SetFileAttributesW(szPath,
|
||||
FILE_ATTRIBUTE_NORMAL);
|
||||
}
|
||||
|
||||
if (!DeleteFileW (szPath))
|
||||
if (!DeleteFileW(szPath))
|
||||
{
|
||||
bResult = FALSE;
|
||||
break;
|
||||
|
@ -299,11 +302,11 @@ RecursiveRemoveDir (LPCWSTR lpPath)
|
|||
}
|
||||
}
|
||||
|
||||
if (!FindNextFileW (hFind, &FindData))
|
||||
if (!FindNextFileW(hFind, &FindData))
|
||||
{
|
||||
if (GetLastError () != ERROR_NO_MORE_FILES)
|
||||
if (GetLastError() != ERROR_NO_MORE_FILES)
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
bResult = FALSE;
|
||||
break;
|
||||
}
|
||||
|
@ -312,20 +315,20 @@ RecursiveRemoveDir (LPCWSTR lpPath)
|
|||
}
|
||||
}
|
||||
|
||||
FindClose (hFind);
|
||||
FindClose(hFind);
|
||||
|
||||
return bResult;
|
||||
}
|
||||
|
||||
|
||||
BOOL
|
||||
RemoveDirectoryPath (LPCWSTR lpPathName)
|
||||
RemoveDirectoryPath(LPCWSTR lpPathName)
|
||||
{
|
||||
if (!RecursiveRemoveDir (lpPathName))
|
||||
if (!RecursiveRemoveDir(lpPathName))
|
||||
return FALSE;
|
||||
|
||||
DPRINT ("Delete directory: '%S'\n", lpPathName);
|
||||
return RemoveDirectoryW (lpPathName);
|
||||
DPRINT("Delete directory: '%S'\n", lpPathName);
|
||||
return RemoveDirectoryW(lpPathName);
|
||||
}
|
||||
|
||||
/* EOF */
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/environment.c
|
||||
* FILE: dll/win32/userenv/environment.c
|
||||
* PURPOSE: User environment functions
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -30,7 +30,8 @@
|
|||
#include <debug.h>
|
||||
|
||||
|
||||
static BOOL
|
||||
static
|
||||
BOOL
|
||||
SetUserEnvironmentVariable(LPVOID *Environment,
|
||||
LPWSTR lpName,
|
||||
LPWSTR lpValue,
|
||||
|
@ -117,7 +118,8 @@ SetUserEnvironmentVariable(LPVOID *Environment,
|
|||
}
|
||||
|
||||
|
||||
static BOOL
|
||||
static
|
||||
BOOL
|
||||
AppendUserEnvironmentVariable(LPVOID *Environment,
|
||||
LPWSTR lpName,
|
||||
LPWSTR lpValue)
|
||||
|
@ -165,7 +167,8 @@ AppendUserEnvironmentVariable(LPVOID *Environment,
|
|||
}
|
||||
|
||||
|
||||
static HKEY
|
||||
static
|
||||
HKEY
|
||||
GetCurrentUserKey(HANDLE hToken)
|
||||
{
|
||||
UNICODE_STRING SidString;
|
||||
|
@ -198,7 +201,8 @@ GetCurrentUserKey(HANDLE hToken)
|
|||
}
|
||||
|
||||
|
||||
static BOOL
|
||||
static
|
||||
BOOL
|
||||
SetUserEnvironment(LPVOID *lpEnvironment,
|
||||
HKEY hKey,
|
||||
LPWSTR lpSubKeyName)
|
||||
|
@ -310,7 +314,8 @@ SetUserEnvironment(LPVOID *lpEnvironment,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
CreateEnvironmentBlock(LPVOID *lpEnvironment,
|
||||
HANDLE hToken,
|
||||
BOOL bInherit)
|
||||
|
@ -454,7 +459,8 @@ CreateEnvironmentBlock(LPVOID *lpEnvironment,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
DestroyEnvironmentBlock(LPVOID lpEnvironment)
|
||||
{
|
||||
DPRINT("DestroyEnvironmentBlock() called\n");
|
||||
|
@ -471,7 +477,8 @@ DestroyEnvironmentBlock(LPVOID lpEnvironment)
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
ExpandEnvironmentStringsForUserW(IN HANDLE hToken,
|
||||
IN LPCWSTR lpSrc,
|
||||
OUT LPWSTR lpDest,
|
||||
|
@ -522,7 +529,8 @@ ExpandEnvironmentStringsForUserW(IN HANDLE hToken,
|
|||
}
|
||||
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
ExpandEnvironmentStringsForUserA(IN HANDLE hToken,
|
||||
IN LPCSTR lpSrc,
|
||||
OUT LPSTR lpDest,
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/gpolicy.c
|
||||
* FILE: dll/win32/userenv/gpolicy.c
|
||||
* PURPOSE: Group policy functions
|
||||
* PROGRAMMER: Thomas Weidenmueller <w3seek@reactos.com>
|
||||
*/
|
||||
|
@ -110,7 +110,8 @@ UninitializeGPNotifications(VOID)
|
|||
DeleteCriticalSection(&GPNotifyLock);
|
||||
}
|
||||
|
||||
static VOID
|
||||
static
|
||||
VOID
|
||||
NotifyGPEvents(IN BOOL bMachine)
|
||||
{
|
||||
PGP_NOTIFY Notify = NotificationList;
|
||||
|
@ -126,7 +127,9 @@ NotifyGPEvents(IN BOOL bMachine)
|
|||
}
|
||||
}
|
||||
|
||||
static DWORD WINAPI
|
||||
static
|
||||
DWORD
|
||||
WINAPI
|
||||
GPNotificationThreadProc(IN LPVOID lpParameter)
|
||||
{
|
||||
HMODULE hModule;
|
||||
|
@ -255,7 +258,8 @@ GPNotificationThreadProc(IN LPVOID lpParameter)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static HANDLE
|
||||
static
|
||||
HANDLE
|
||||
CreateGPEvent(IN BOOL bMachine,
|
||||
IN PSECURITY_DESCRIPTOR lpSecurityDescriptor)
|
||||
{
|
||||
|
@ -274,7 +278,8 @@ CreateGPEvent(IN BOOL bMachine,
|
|||
return hEvent;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
RegisterGPNotification(IN HANDLE hEvent,
|
||||
IN BOOL bMachine)
|
||||
{
|
||||
|
@ -378,7 +383,8 @@ Cleanup:
|
|||
return Ret;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
UnregisterGPNotification(IN HANDLE hEvent)
|
||||
{
|
||||
PGP_NOTIFY Notify = NULL, *NotifyLink;
|
||||
|
@ -418,7 +424,8 @@ UnregisterGPNotification(IN HANDLE hEvent)
|
|||
return Ret;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
RefreshPolicy(IN BOOL bMachine)
|
||||
{
|
||||
HANDLE hEvent;
|
||||
|
@ -437,7 +444,8 @@ RefreshPolicy(IN BOOL bMachine)
|
|||
return Ret;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
RefreshPolicyEx(IN BOOL bMachine,
|
||||
IN DWORD dwOptions)
|
||||
{
|
||||
|
@ -470,7 +478,8 @@ RefreshPolicyEx(IN BOOL bMachine,
|
|||
}
|
||||
}
|
||||
|
||||
HANDLE WINAPI
|
||||
HANDLE
|
||||
WINAPI
|
||||
EnterCriticalPolicySection(IN BOOL bMachine)
|
||||
{
|
||||
SECURITY_ATTRIBUTES SecurityAttributes;
|
||||
|
@ -507,7 +516,8 @@ EnterCriticalPolicySection(IN BOOL bMachine)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
LeaveCriticalPolicySection(IN HANDLE hSection)
|
||||
{
|
||||
BOOL Ret;
|
||||
|
@ -524,7 +534,8 @@ LeaveCriticalPolicySection(IN HANDLE hSection)
|
|||
return Ret;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
WaitForUserPolicyForegroundProcessing(VOID)
|
||||
{
|
||||
HANDLE hEvent;
|
||||
|
@ -543,7 +554,8 @@ WaitForUserPolicyForegroundProcessing(VOID)
|
|||
return Ret;
|
||||
}
|
||||
|
||||
BOOL WINAPI
|
||||
BOOL
|
||||
WINAPI
|
||||
WaitForMachinePolicyForegroundProcessing(VOID)
|
||||
{
|
||||
HANDLE hEvent;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/internal.h
|
||||
* FILE: dll/win32/userenv/internal.h
|
||||
* PURPOSE: internal stuff
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -29,15 +29,15 @@
|
|||
|
||||
/* directory.c */
|
||||
BOOL
|
||||
CopyDirectory (LPCWSTR lpDestinationPath,
|
||||
CopyDirectory(LPCWSTR lpDestinationPath,
|
||||
LPCWSTR lpSourcePath);
|
||||
|
||||
BOOL
|
||||
CreateDirectoryPath (LPCWSTR lpPathName,
|
||||
CreateDirectoryPath(LPCWSTR lpPathName,
|
||||
LPSECURITY_ATTRIBUTES lpSecurityAttributes);
|
||||
|
||||
BOOL
|
||||
RemoveDirectoryPath (LPCWSTR lpPathName);
|
||||
RemoveDirectoryPath(LPCWSTR lpPathName);
|
||||
|
||||
/* misc.c */
|
||||
typedef struct _DYN_FUNCS
|
||||
|
@ -64,16 +64,17 @@ typedef struct _DYN_MODULE
|
|||
extern DYN_MODULE DynOle32;
|
||||
|
||||
BOOL
|
||||
LoadDynamicImports(PDYN_MODULE Module, PDYN_FUNCS DynFuncs);
|
||||
LoadDynamicImports(PDYN_MODULE Module,
|
||||
PDYN_FUNCS DynFuncs);
|
||||
|
||||
VOID
|
||||
UnloadDynamicImports(PDYN_FUNCS DynFuncs);
|
||||
|
||||
LPWSTR
|
||||
AppendBackslash (LPWSTR String);
|
||||
AppendBackslash(LPWSTR String);
|
||||
|
||||
BOOL
|
||||
GetUserSidFromToken (HANDLE hToken,
|
||||
GetUserSidFromToken(HANDLE hToken,
|
||||
PUNICODE_STRING SidString);
|
||||
|
||||
PSECURITY_DESCRIPTOR
|
||||
|
@ -81,12 +82,12 @@ CreateDefaultSecurityDescriptor(VOID);
|
|||
|
||||
/* profile.c */
|
||||
BOOL
|
||||
AppendSystemPostfix (LPWSTR lpName,
|
||||
AppendSystemPostfix(LPWSTR lpName,
|
||||
DWORD dwMaxLength);
|
||||
|
||||
/* registry.c */
|
||||
BOOL
|
||||
CreateUserHive (LPCWSTR lpKeyName,
|
||||
CreateUserHive(LPCWSTR lpKeyName,
|
||||
LPCWSTR lpProfilePath);
|
||||
|
||||
/* setup.c */
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/misc.c
|
||||
* FILE: dll/win32/userenv/misc.c
|
||||
* PURPOSE: User profile code
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -35,11 +35,11 @@ static SID_IDENTIFIER_AUTHORITY WorldAuthority = {SECURITY_WORLD_SID_AUTHORITY};
|
|||
/* FUNCTIONS ***************************************************************/
|
||||
|
||||
LPWSTR
|
||||
AppendBackslash (LPWSTR String)
|
||||
AppendBackslash(LPWSTR String)
|
||||
{
|
||||
ULONG Length;
|
||||
|
||||
Length = lstrlenW (String);
|
||||
Length = lstrlenW(String);
|
||||
if (String[Length - 1] != L'\\')
|
||||
{
|
||||
String[Length] = L'\\';
|
||||
|
@ -52,7 +52,7 @@ AppendBackslash (LPWSTR String)
|
|||
|
||||
|
||||
BOOL
|
||||
GetUserSidFromToken (HANDLE hToken,
|
||||
GetUserSidFromToken(HANDLE hToken,
|
||||
PUNICODE_STRING SidString)
|
||||
{
|
||||
PSID_AND_ATTRIBUTES SidBuffer, nsb;
|
||||
|
@ -60,19 +60,19 @@ GetUserSidFromToken (HANDLE hToken,
|
|||
NTSTATUS Status;
|
||||
|
||||
Length = 256;
|
||||
SidBuffer = LocalAlloc (LMEM_FIXED,
|
||||
SidBuffer = LocalAlloc(LMEM_FIXED,
|
||||
Length);
|
||||
if (SidBuffer == NULL)
|
||||
return FALSE;
|
||||
|
||||
Status = NtQueryInformationToken (hToken,
|
||||
Status = NtQueryInformationToken(hToken,
|
||||
TokenUser,
|
||||
(PVOID)SidBuffer,
|
||||
Length,
|
||||
&Length);
|
||||
if (Status == STATUS_BUFFER_TOO_SMALL)
|
||||
{
|
||||
nsb = LocalReAlloc (SidBuffer,
|
||||
nsb = LocalReAlloc(SidBuffer,
|
||||
Length,
|
||||
LMEM_MOVEABLE);
|
||||
if (nsb == NULL)
|
||||
|
@ -82,7 +82,7 @@ GetUserSidFromToken (HANDLE hToken,
|
|||
}
|
||||
|
||||
SidBuffer = nsb;
|
||||
Status = NtQueryInformationToken (hToken,
|
||||
Status = NtQueryInformationToken(hToken,
|
||||
TokenUser,
|
||||
(PVOID)SidBuffer,
|
||||
Length,
|
||||
|
@ -91,28 +91,28 @@ GetUserSidFromToken (HANDLE hToken,
|
|||
|
||||
if (!NT_SUCCESS (Status))
|
||||
{
|
||||
LocalFree ((HLOCAL)SidBuffer);
|
||||
SetLastError (RtlNtStatusToDosError (Status));
|
||||
LocalFree((HLOCAL)SidBuffer);
|
||||
SetLastError(RtlNtStatusToDosError(Status));
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DPRINT ("SidLength: %lu\n", RtlLengthSid (SidBuffer[0].Sid));
|
||||
DPRINT("SidLength: %lu\n", RtlLengthSid (SidBuffer[0].Sid));
|
||||
|
||||
Status = RtlConvertSidToUnicodeString (SidString,
|
||||
Status = RtlConvertSidToUnicodeString(SidString,
|
||||
SidBuffer[0].Sid,
|
||||
TRUE);
|
||||
|
||||
LocalFree ((HLOCAL)SidBuffer);
|
||||
LocalFree((HLOCAL)SidBuffer);
|
||||
|
||||
if (!NT_SUCCESS (Status))
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
SetLastError (RtlNtStatusToDosError (Status));
|
||||
SetLastError(RtlNtStatusToDosError(Status));
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DPRINT ("SidString.Length: %lu\n", SidString->Length);
|
||||
DPRINT ("SidString.MaximumLength: %lu\n", SidString->MaximumLength);
|
||||
DPRINT ("SidString: '%wZ'\n", SidString);
|
||||
DPRINT("SidString.Length: %lu\n", SidString->Length);
|
||||
DPRINT("SidString.MaximumLength: %lu\n", SidString->MaximumLength);
|
||||
DPRINT("SidString: '%wZ'\n", SidString);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -284,7 +284,8 @@ DYN_MODULE DynOle32 =
|
|||
* has been created!
|
||||
*/
|
||||
BOOL
|
||||
LoadDynamicImports(PDYN_MODULE Module, PDYN_FUNCS DynFuncs)
|
||||
LoadDynamicImports(PDYN_MODULE Module,
|
||||
PDYN_FUNCS DynFuncs)
|
||||
{
|
||||
LPSTR *fname;
|
||||
PVOID *fn;
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/profile.c
|
||||
* FILE: dll/win32/userenv/profile.c
|
||||
* PURPOSE: User profile code
|
||||
* PROGRAMMERS: Eric Kohl
|
||||
* Hervé Poussineau
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/registry.c
|
||||
* FILE: dll/win32/userenv/registry.c
|
||||
* PURPOSE: User profile code
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -32,8 +32,9 @@
|
|||
|
||||
/* FUNCTIONS ***************************************************************/
|
||||
|
||||
static BOOL
|
||||
CopyKey (HKEY hDstKey,
|
||||
static
|
||||
BOOL
|
||||
CopyKey(HKEY hDstKey,
|
||||
HKEY hSrcKey)
|
||||
{
|
||||
LONG Error;
|
||||
|
@ -70,7 +71,7 @@ CopyKey (HKEY hDstKey,
|
|||
|
||||
DPRINT ("CopyKey() called \n");
|
||||
|
||||
Error = RegQueryInfoKey (hSrcKey,
|
||||
Error = RegQueryInfoKey(hSrcKey,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -84,21 +85,21 @@ CopyKey (HKEY hDstKey,
|
|||
NULL);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("RegQueryInfoKey() failed (Error %lu)\n", Error);
|
||||
DPRINT1("RegQueryInfoKey() failed (Error %lu)\n", Error);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DPRINT ("dwSubKeys %lu\n", dwSubKeys);
|
||||
DPRINT ("dwMaxSubKeyNameLength %lu\n", dwMaxSubKeyNameLength);
|
||||
DPRINT ("dwValues %lu\n", dwValues);
|
||||
DPRINT ("dwMaxValueNameLength %lu\n", dwMaxValueNameLength);
|
||||
DPRINT ("dwMaxValueLength %lu\n", dwMaxValueLength);
|
||||
DPRINT("dwSubKeys %lu\n", dwSubKeys);
|
||||
DPRINT("dwMaxSubKeyNameLength %lu\n", dwMaxSubKeyNameLength);
|
||||
DPRINT("dwValues %lu\n", dwValues);
|
||||
DPRINT("dwMaxValueNameLength %lu\n", dwMaxValueNameLength);
|
||||
DPRINT("dwMaxValueLength %lu\n", dwMaxValueLength);
|
||||
|
||||
/* Copy subkeys */
|
||||
if (dwSubKeys != 0)
|
||||
{
|
||||
lpNameBuffer = HeapAlloc (GetProcessHeap (),
|
||||
lpNameBuffer = HeapAlloc(GetProcessHeap(),
|
||||
0,
|
||||
dwMaxSubKeyNameLength * sizeof(WCHAR));
|
||||
if (lpNameBuffer == NULL)
|
||||
|
@ -111,7 +112,7 @@ CopyKey (HKEY hDstKey,
|
|||
for (i = 0; i < dwSubKeys; i++)
|
||||
{
|
||||
dwSubKeyNameLength = dwMaxSubKeyNameLength;
|
||||
Error = RegEnumKeyExW (hSrcKey,
|
||||
Error = RegEnumKeyExW(hSrcKey,
|
||||
i,
|
||||
lpNameBuffer,
|
||||
&dwSubKeyNameLength,
|
||||
|
@ -121,15 +122,15 @@ CopyKey (HKEY hDstKey,
|
|||
&LastWrite);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("Subkey enumeration failed (Error %lu)\n", Error);
|
||||
HeapFree (GetProcessHeap (),
|
||||
DPRINT1("Subkey enumeration failed (Error %lu)\n", Error);
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
Error = RegCreateKeyExW (hDstKey,
|
||||
Error = RegCreateKeyExW(hDstKey,
|
||||
lpNameBuffer,
|
||||
0,
|
||||
NULL,
|
||||
|
@ -140,47 +141,47 @@ CopyKey (HKEY hDstKey,
|
|||
&dwDisposition);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("Subkey creation failed (Error %lu)\n", Error);
|
||||
HeapFree (GetProcessHeap (),
|
||||
DPRINT1("Subkey creation failed (Error %lu)\n", Error);
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
Error = RegOpenKeyExW (hSrcKey,
|
||||
Error = RegOpenKeyExW(hSrcKey,
|
||||
lpNameBuffer,
|
||||
0,
|
||||
KEY_READ,
|
||||
&hSrcSubKey);
|
||||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", Error);
|
||||
RegCloseKey (hDstSubKey);
|
||||
HeapFree (GetProcessHeap (),
|
||||
DPRINT1("Error: %lu\n", Error);
|
||||
RegCloseKey(hDstSubKey);
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (!CopyKey (hDstSubKey,
|
||||
if (!CopyKey(hDstSubKey,
|
||||
hSrcSubKey))
|
||||
{
|
||||
DPRINT1 ("Error: %lu\n", GetLastError());
|
||||
DPRINT1("Error: %lu\n", GetLastError());
|
||||
RegCloseKey (hSrcSubKey);
|
||||
RegCloseKey (hDstSubKey);
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
RegCloseKey (hSrcSubKey);
|
||||
RegCloseKey (hDstSubKey);
|
||||
RegCloseKey(hSrcSubKey);
|
||||
RegCloseKey(hDstSubKey);
|
||||
}
|
||||
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
}
|
||||
|
@ -188,23 +189,23 @@ CopyKey (HKEY hDstKey,
|
|||
/* Copy values */
|
||||
if (dwValues != 0)
|
||||
{
|
||||
lpNameBuffer = HeapAlloc (GetProcessHeap (),
|
||||
lpNameBuffer = HeapAlloc(GetProcessHeap(),
|
||||
0,
|
||||
dwMaxValueNameLength * sizeof(WCHAR));
|
||||
if (lpNameBuffer == NULL)
|
||||
{
|
||||
DPRINT1 ("Buffer allocation failed\n");
|
||||
DPRINT1("Buffer allocation failed\n");
|
||||
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
lpDataBuffer = HeapAlloc (GetProcessHeap (),
|
||||
lpDataBuffer = HeapAlloc(GetProcessHeap(),
|
||||
0,
|
||||
dwMaxValueLength);
|
||||
if (lpDataBuffer == NULL)
|
||||
{
|
||||
DPRINT1 ("Buffer allocation failed\n");
|
||||
HeapFree (GetProcessHeap (),
|
||||
DPRINT1("Buffer allocation failed\n");
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
||||
|
@ -215,7 +216,7 @@ CopyKey (HKEY hDstKey,
|
|||
{
|
||||
dwValueNameLength = dwMaxValueNameLength;
|
||||
dwValueLength = dwMaxValueLength;
|
||||
Error = RegEnumValueW (hSrcKey,
|
||||
Error = RegEnumValueW(hSrcKey,
|
||||
i,
|
||||
lpNameBuffer,
|
||||
&dwValueNameLength,
|
||||
|
@ -226,17 +227,17 @@ CopyKey (HKEY hDstKey,
|
|||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1("Error: %lu\n", Error);
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpDataBuffer);
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError((DWORD)Error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
Error = RegSetValueExW (hDstKey,
|
||||
Error = RegSetValueExW(hDstKey,
|
||||
lpNameBuffer,
|
||||
0,
|
||||
dwType,
|
||||
|
@ -245,10 +246,10 @@ CopyKey (HKEY hDstKey,
|
|||
if (Error != ERROR_SUCCESS)
|
||||
{
|
||||
DPRINT1("Error: %lu\n", Error);
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpDataBuffer);
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
SetLastError((DWORD)Error);
|
||||
|
@ -256,16 +257,16 @@ CopyKey (HKEY hDstKey,
|
|||
}
|
||||
}
|
||||
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpDataBuffer);
|
||||
|
||||
HeapFree (GetProcessHeap (),
|
||||
HeapFree(GetProcessHeap(),
|
||||
0,
|
||||
lpNameBuffer);
|
||||
}
|
||||
|
||||
DPRINT ("CopyKey() done \n");
|
||||
DPRINT("CopyKey() done \n");
|
||||
|
||||
return TRUE;
|
||||
#endif
|
||||
|
@ -273,7 +274,7 @@ CopyKey (HKEY hDstKey,
|
|||
|
||||
|
||||
BOOL
|
||||
CreateUserHive (LPCWSTR lpKeyName,
|
||||
CreateUserHive(LPCWSTR lpKeyName,
|
||||
LPCWSTR lpProfilePath)
|
||||
{
|
||||
HKEY hDefaultKey = NULL;
|
||||
|
@ -281,9 +282,9 @@ CreateUserHive (LPCWSTR lpKeyName,
|
|||
LONG Error;
|
||||
BOOL Ret = FALSE;
|
||||
|
||||
DPRINT ("CreateUserHive(%S) called\n", lpKeyName);
|
||||
DPRINT("CreateUserHive(%S) called\n", lpKeyName);
|
||||
|
||||
Error = RegOpenKeyExW (HKEY_USERS,
|
||||
Error = RegOpenKeyExW(HKEY_USERS,
|
||||
L".Default",
|
||||
0,
|
||||
KEY_READ,
|
||||
|
@ -294,7 +295,7 @@ CreateUserHive (LPCWSTR lpKeyName,
|
|||
goto Cleanup;
|
||||
}
|
||||
|
||||
Error = RegOpenKeyExW (HKEY_USERS,
|
||||
Error = RegOpenKeyExW(HKEY_USERS,
|
||||
lpKeyName,
|
||||
0,
|
||||
KEY_ALL_ACCESS,
|
||||
|
@ -316,7 +317,7 @@ CreateUserHive (LPCWSTR lpKeyName,
|
|||
goto Cleanup;
|
||||
}
|
||||
|
||||
RegFlushKey (hUserKey);
|
||||
RegFlushKey(hUserKey);
|
||||
Ret = TRUE;
|
||||
|
||||
Cleanup:
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/resource.h
|
||||
* FILE: dll/win32/userenv/resource.h
|
||||
* PURPOSE: Resource IDs
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/setup.c
|
||||
* FILE: dll/win32/userenv/setup.c
|
||||
* PURPOSE: Profile setup functions
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/userenv/userenv.c
|
||||
* FILE: dll/win32/userenv/userenv.c
|
||||
* PURPOSE: DLL initialization code
|
||||
* PROGRAMMER: Eric Kohl
|
||||
*/
|
||||
|
@ -31,8 +31,9 @@
|
|||
|
||||
HINSTANCE hInstance = NULL;
|
||||
|
||||
BOOL WINAPI
|
||||
DllMain (HINSTANCE hinstDLL,
|
||||
BOOL
|
||||
WINAPI
|
||||
DllMain(HINSTANCE hinstDLL,
|
||||
DWORD fdwReason,
|
||||
LPVOID lpvReserved)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue