diff options
author | Christopher Faylor <me@cgf.cx> | 2002-08-16 00:34:49 +0400 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2002-08-16 00:34:49 +0400 |
commit | a54ad580fc13fd76020c6042cea1a7884e87a946 (patch) | |
tree | 4e62ce8acc6c17ad5c85de633ac069a8813f167e /winsup/cygwin | |
parent | bb55ce4cc1b588055f9f6feb3550659fe036c55a (diff) |
* dcrt0.cc: Modify define for CYGWIN_GUARD.
(alloc_stack_hard_way): Just use CYGWIN_GUARD in VirtualAlloc call.
Diffstat (limited to 'winsup/cygwin')
-rw-r--r-- | winsup/cygwin/ChangeLog | 5 | ||||
-rw-r--r-- | winsup/cygwin/dcrt0.cc | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index cd85e17af..53535e0d2 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2002-08-15 Thomas Pfaff <tpfaff@gmx.net> + + * dcrt0.cc: Modify define for CYGWIN_GUARD. + (alloc_stack_hard_way): Just use CYGWIN_GUARD in VirtualAlloc call. + 2002-08-11 Conrad Scott <conrad.scott@dsl.pipex.com> * fhandler.h (fhandler_socket::recv): Remove method. diff --git a/winsup/cygwin/dcrt0.cc b/winsup/cygwin/dcrt0.cc index c5c6272a8..e13665dab 100644 --- a/winsup/cygwin/dcrt0.cc +++ b/winsup/cygwin/dcrt0.cc @@ -457,7 +457,8 @@ check_sanity_and_sync (per_process *p) child_info NO_COPY *child_proc_info = NULL; static MEMORY_BASIC_INFORMATION NO_COPY sm; -#define CYGWIN_GUARD ((wincap.has_page_guard ()) ? PAGE_GUARD : PAGE_NOACCESS) +#define CYGWIN_GUARD ((wincap.has_page_guard ()) ? \ + PAGE_EXECUTE_READWRITE|PAGE_GUARD : PAGE_NOACCESS) // __inline__ void extern void @@ -498,7 +499,7 @@ alloc_stack_hard_way (child_info_fork *ci, volatile char *b) { m.BaseAddress = (LPVOID)((DWORD)m.BaseAddress - 1); if (!VirtualAlloc ((LPVOID) m.BaseAddress, 1, MEM_COMMIT, - PAGE_EXECUTE_READWRITE|CYGWIN_GUARD)) + CYGWIN_GUARD)) api_fatal ("fork: couldn't allocate new stack guard page %p, %E", m.BaseAddress); } |