loader: On Mac, reserve the process's original thread for the frameworks. (try 2)

Alexandre Julliard julliard at winehq.org
Sat Nov 13 04:09:17 CST 2010

Ken Thomases <ken at codeweavers.com> writes:

> I suppose we could put a loop around the exec call, such that we sleep
> and retry if it returns ENOTSUP.  However, if terminate_main_thread
> was unsuccessful, or if ENOTSUP can occur for other reasons, that
> might be an infinite loop.

That would be preferable. To avoid an infinite loop you can do an
exponential wait with a limit or something like that. Also you should
only try to terminate the main thread when execve actually fails, this
way there's no penalty if the OS doesn't have the ENOTSUP bug.

Alexandre Julliard
julliard at winehq.org

More information about the wine-devel mailing list