mirror of
git://sourceware.org/git/newlib-cygwin.git
synced 2025-02-10 11:09:25 +08:00
A hang was encountered, apparently triggered by commit 63b503916d42, changing tls_pathbufs from malloc'ed to HeapAlloc'ed memory. After lengthy debugging it transpired that adding the heap handle to the tls_pathbuf struct added 8 bytes to the cygtls area, thus moving the "context" member by 8 bytes, too, so it was suddently unaligned. Fix this for now by changing the alignment. Fix this once and for all, by adding code to the gentls_offsets script to check if the alignment of the "context" member is 16 bytes. If not, print a matching error message, remove the just generated file, and exit with error. FIXME: It would be really nice to find a way to auomate the correct alignment of the "context" member, but I don't see any way to use alignment attributes to get what we need here. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>