mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-14 16:00:44 +02:00
Due to an incorrect pointer check, we were never setting the sigaltstack on 32-bit applications. Additionally the stack_t type didn't have the members in the correct order. This fixes wine 32-bit applications where wine sends an application SIGUSR1 and expects the altstack to be used. This is because the altstack has the thread's TEB region at the start of the stack. Without this when the application was getting sent a SIGUSR1, it would remain in the application stack, thus getting an invalid TEB and loading an FS register with zero.