Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2002-05-06 14:05:46 +0400
committerCorinna Vinschen <corinna@vinschen.de>2002-05-06 14:05:46 +0400
commita9917779940a314185fa33c177a45fd12502935c (patch)
tree9f4a874d8b7c7eb8a9d318d4790017acedba59a1 /winsup/cygwin/registry.cc
parent3d9bc8a6171538504fc61aac2a1e43022b334034 (diff)
* spawn.cc (spawn_guts): Move call to set_process_privilege()
to load_registry_hive(). * registry.cc (load_registry_hive): ditto. * fork.cc (fork_parent): Call sec_user_nih() only once.
Diffstat (limited to 'winsup/cygwin/registry.cc')
-rw-r--r--winsup/cygwin/registry.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/winsup/cygwin/registry.cc b/winsup/cygwin/registry.cc
index 3ed1a80bb..4d2bb2b5a 100644
--- a/winsup/cygwin/registry.cc
+++ b/winsup/cygwin/registry.cc
@@ -235,12 +235,13 @@ load_registry_hive (PSID psid)
/* Check if user hive is already loaded. */
cygsid csid (psid);
csid.string (sid);
- if (!RegOpenKeyExA (HKEY_USERS, csid.string (sid), 0, KEY_READ, &hkey))
+ if (!RegOpenKeyExA (HKEY_USERS, sid, 0, KEY_READ, &hkey))
{
debug_printf ("User registry hive for %s already exists", sid);
RegCloseKey (hkey);
return;
}
+ set_process_privilege (SE_RESTORE_NAME);
if (get_registry_hive_path (psid, path))
{
strcat (path, "\\NTUSER.DAT");