[Bug 21917] SC2 'LazyLaunch' v2.0 fails with 'Exception frame is not in stack limits => unable to dispatch exception.' (TLS callbacks can taint EBP, needs assembly wrapper)

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Sep 6 19:20:45 CDT 2014


https://bugs.winehq.org/show_bug.cgi?id=21917

Sebastian Lackner <sebastian at fds-team.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sebastian at fds-team.de

--- Comment #10 from Sebastian Lackner <sebastian at fds-team.de> ---
I'm wondering why noone worked on this, although the solution is well-known
since two years? Anyway, here are some patches which seem to fix the issue for
me:

https://github.com/compholio/wine-compholio/blob/master/patches/ntdll-Save_Regs_Entrypoint/0001-ntdll-Save-more-registers-in-call_dll_entry_point-on.patch

https://github.com/compholio/wine-compholio/blob/master/patches/ntdll-Save_Regs_Entrypoint/0002-ntdll-Use-call_dll_entry_point-to-execute-TLS-callba.patch

Will try to get them upstream during the next week(s). I'm still not completely
happy about the fact that this code cannot handle when esi is modified, but its
probably better than having to rely on the stack pointer. The alternative
solution would be to enforce some align before the function call (gcc should
already do that, but its probably better to enforce it), and then round esp
afterwards to get appropriate pointers to the saved registerss... but there is
no guarantee that the Windows code will always use "ret {0,4,8,12}", it could
also use a jump or other weird methods ... :/

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list