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:
authorChristopher Faylor <me@cgf.cx>2000-09-30 08:54:11 +0400
committerChristopher Faylor <me@cgf.cx>2000-09-30 08:54:11 +0400
commit8d82847a29d4717e225c56bda43a99ec703e2836 (patch)
treef8ab3ea68e096b050c4a4ddc5ce5e8bfe70633ec /winsup/cygwin/fork.cc
parent90fe77395a80903e2bec1b00534b442082dfe4b2 (diff)
* cygheap.cc (init_cheap): Set aside space for heap walk pointer.
(_csbrk): Make logic for detecting when to alloc cognizant of initialization condition. (_cmalloc): Use a structure to hold bucket size and heap chain pointer. Store pointer to next freed block in bucket size location so that it will be easy to see if a block is allocated. (_cfree): Store pointer to next freed block in bucket size location. (_crealloc): Use macro to retrieve bucket size. (cygheap_init): Eliminate. (cygheap_fixup_in_child): Add second argument to determine if we were execed or not. In execed case, walk the heap, cleaning up any orphaned blocks. * cygheap.h: Add a "MAX" value to cygheap_types. Remove cygheap_init declaration. Accomodate new argument to cygheap_fixup_in child. * fork.cc (fork): Accomodate extra argument to cygheap_fixup_in_child. * dcrt0.cc (dll_crt0_1): Ditto. Remove call to cygheap_init.
Diffstat (limited to 'winsup/cygwin/fork.cc')
-rw-r--r--winsup/cygwin/fork.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc
index 02b784a6a..7f77a5f98 100644
--- a/winsup/cygwin/fork.cc
+++ b/winsup/cygwin/fork.cc
@@ -571,7 +571,7 @@ fork ()
MALLOC_CHECK;
- cygheap_fixup_in_child (hParent);
+ cygheap_fixup_in_child (hParent, 0);
fdtab.fixup_after_fork (hParent);
signal_fixup_after_fork ();
exec_fixup_after_fork ();