aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/cygheap.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2001-01-29 00:46:25 +0000
committerChristopher Faylor <me@cgf.cx>2001-01-29 00:46:25 +0000
commit6a4878cf1617f051e4706ce30f7c8607ebf2e85d (patch)
tree2a3a69edf8e8000644a0ff5d69fcd68fa6dbc101 /winsup/cygwin/cygheap.cc
parent39d871d66d6ce0c49dc669f2d8e2f55414579bcf (diff)
downloadnewlib-6a4878cf1617f051e4706ce30f7c8607ebf2e85d.zip
newlib-6a4878cf1617f051e4706ce30f7c8607ebf2e85d.tar.gz
newlib-6a4878cf1617f051e4706ce30f7c8607ebf2e85d.tar.bz2
* syscalls.cc (_link): Make sure that newpath does not exist. Set errno if it
does. * cygheap.cc (init_cheap): Don't specify a load address for the heap. It doesn't work on #!*& Windows 9x. (cygheap_init): Move GetUserName to memory_init. * dcrt0.cc (dll_crt0_1): Call new memory_init functin, eliminate call to heap_init. * heap.cc (heap_init): Improve error output. * heap.h: Correct some declarations. * shared.cc (mount_table_init): Remove. (memory_init): Renamed from shared_init. Reorganize to accomodate strange Windows 9x problems with cygheap/heap interaction. * shared_info.h: Rename shared_init to memory_init.
Diffstat (limited to 'winsup/cygwin/cygheap.cc')
-rw-r--r--winsup/cygwin/cygheap.cc11
1 files changed, 1 insertions, 10 deletions
diff --git a/winsup/cygwin/cygheap.cc b/winsup/cygwin/cygheap.cc
index 10c16d1..49a819a 100644
--- a/winsup/cygwin/cygheap.cc
+++ b/winsup/cygwin/cygheap.cc
@@ -27,8 +27,7 @@ static NO_COPY muto *cygheap_protect = NULL;
inline static void
init_cheap ()
{
- void *addr = cygheap_address;
- cygheap = (init_cygheap *) VirtualAlloc (addr, CYGHEAPSIZE, MEM_RESERVE, PAGE_NOACCESS);
+ cygheap = (init_cygheap *) VirtualAlloc (NULL, CYGHEAPSIZE, MEM_RESERVE, PAGE_NOACCESS);
if (!cygheap)
api_fatal ("Couldn't reserve space for cygwin's heap, %E");
cygheap_max = cygheap + 1;
@@ -67,14 +66,6 @@ cygheap_init ()
{
cygheap_protect = new_muto (FALSE, "cygheap_protect");
_csbrk (0);
-
- char username[MAX_USER_NAME];
- DWORD username_len = MAX_USER_NAME;
-
- if (!GetUserName (username, &username_len))
- cygheap->user.set_name ("unknown");
- else
- cygheap->user.set_name (username);
}
/* Copyright (C) 1997, 2000 DJ Delorie */