summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/shared.cc
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2014-10-17 14:36:59 +0000
committerCorinna Vinschen <corinna@vinschen.de>2014-10-17 14:36:59 +0000
commitcc5a7d7519f6e18247e2c301dcf48a9b9417caaf (patch)
tree75e2bf1f81c048eb086cbf5edb6d51fa09c18ca9 /winsup/cygwin/shared.cc
parent1f0bd6f96fec4d2ccc89f404e14c309ef30b649a (diff)
downloadcygnal-cc5a7d7519f6e18247e2c301dcf48a9b9417caaf.tar.gz
cygnal-cc5a7d7519f6e18247e2c301dcf48a9b9417caaf.tar.bz2
cygnal-cc5a7d7519f6e18247e2c301dcf48a9b9417caaf.zip
* cygheap.cc (cygheap_fixup_in_child): Call set_dll_dir.
(init_cygheap::init_installation_root): Just memmove contents of installation_root instead of calling GetModuleFileNameW again. Copy installation_root to installation_dir before stripping of "bin" dir. Don't call SetDllDirectory here. Explain what we do. (setup_cygheap): New function taking over initial cygheap setup from memory_init. Additionally call set_dll_dir. * cygheap.h (struct init_cygheap): Add installation_dir member. (init_cygheap::set_dll_dir): Define. (setup_cygheap): Declare. * dcrt0.cc: Throughout drop parameter from memory_init call. (dll_crt0_0): Call setup_cygheap prior to memory_init. * dlfcn.cc (dlopen): Change comment to point to the right function. * shared.cc (memory_init): Drop parameter. Drop cygheap setup. * shared_info.h (memory_init): Change declaration accordingly.
Diffstat (limited to 'winsup/cygwin/shared.cc')
-rw-r--r--winsup/cygwin/shared.cc11
1 files changed, 1 insertions, 10 deletions
diff --git a/winsup/cygwin/shared.cc b/winsup/cygwin/shared.cc
index 9f1f27cd9..4510d02ab 100644
--- a/winsup/cygwin/shared.cc
+++ b/winsup/cygwin/shared.cc
@@ -343,17 +343,8 @@ shared_info::initialize ()
}
void
-memory_init (bool init_cygheap)
+memory_init ()
{
- /* Initialize the Cygwin heap, if necessary */
- if (init_cygheap)
- {
- cygheap_init ();
- cygheap->user.init ();
- cygheap->init_installation_root (); /* Requires user.init! */
- cygheap->pg.init ();
- }
-
shared_info::create (); /* Initialize global shared memory */
user_info::create (false); /* Initialize per-user shared memory */
/* Initialize tty list session stuff. Doesn't really belong here but