Patch to fix ntdll:exception tests on Mac OS

Charles Davis cdavis at
Mon Feb 7 11:40:43 CST 2011


This is a small patch I wrote to fix the exception tests on Mac OS X.
Right now, if you look at the Mac results I submitted, you'll notice
that there are two failures.

The first failure happens because Mach doesn't allow the 'global' flag
to be set when setting the debug registers. Changing the test not to set
the global flag causes the test to pass. I get the feeling, though, that
there is a good reason the global flag was set, so I'm reluctant to send
that change in.

The other failure happens because 32-bit Mac OS only protects stacks
from execution. If you clear PROT_EXEC on any other data, you can still
execute code from it. (64-bit Mac OS, on the other hand, always respects
the PROT_EXEC flag.) I changed ntdll on 32-bit Mac OS to report DEP as
permanently disabled, but I wonder if this was the right change to make.

I just want to know: am I doing the right thing here? If not, what
should I do instead to fix the tests?

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0001-ntdll-Fix-exception-tests-on-Mac-OS.patch
URL: <>

More information about the wine-devel mailing list