Josh DuBois wrote:
@@ -3396,7 +3428,7 @@ HANDLE OwningThread; HANDLE LockSemaphore; ULONG_PTR SpinCount; -} RTL_CRITICAL_SECTION, *PRTL_CRITICAL_SECTION; +} __attribute__ ((aligned (4))) RTL_CRITICAL_SECTION, *PRTL_CRITICAL_SECTION;
Why? The default alignment of this struct is 4 anyway (as all its members have a default alignment of 4 ...)
The only situation where a RTL_CRITICAL_SECTION could conceivably be not aligned to 4 would be if if were embedded into a packed struct. In this case, however, the aligned attribute wouldn't help either AFAIK.
(Additionally, the gcc'ism will annoy Patrik ;-/)
Bye, Ulrich