diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2015-07-29 13:32:29 +0200 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2015-07-29 13:32:29 +0200 |
commit | 6ab56bdd3f92982fcb9e7d093c3fd1b56c2b306f (patch) | |
tree | 5b2e82f0b7a5f36ae4451e0416fb8fabee626b0e /winsup/cygwin/cygtls.h | |
parent | 9753bc33335b08426d6d85c5d833f40c5401c649 (diff) | |
download | newlib-6ab56bdd3f92982fcb9e7d093c3fd1b56c2b306f.zip newlib-6ab56bdd3f92982fcb9e7d093c3fd1b56c2b306f.tar.gz newlib-6ab56bdd3f92982fcb9e7d093c3fd1b56c2b306f.tar.bz2 |
cygwin: Fix crashes under AllocationPreference=0x100000 condition
* cygtls.h: Include cygtls_padsize.h and define CYGTLS_PADSIZE there.
* cygtls_padsize.h: New file. Define CYGTLS_PADSIZE.
* environ.cc (parse_options): Fix NULL pointer access.
* init.cc (threadfunc_fe): Do not force stack align on x86_64.
* strace.cc (main2): Rename from main.
(main): Make room for _cygtls area on stack and just call main2. Add
comment to explain why.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/cygwin/cygtls.h')
-rw-r--r-- | winsup/cygwin/cygtls.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/winsup/cygwin/cygtls.h b/winsup/cygwin/cygtls.h index 91ed4d4..c8615af 100644 --- a/winsup/cygwin/cygtls.h +++ b/winsup/cygwin/cygtls.h @@ -271,12 +271,7 @@ private: }; #pragma pack(pop) -/* FIXME: Find some way to autogenerate this value */ -#ifdef __x86_64__ -const int CYGTLS_PADSIZE = 12800; /* Must be 16-byte aligned */ -#else -const int CYGTLS_PADSIZE = 12700; -#endif +#include "cygtls_padsize.h" /*gentls_offsets*/ |