On 10/16/06, Gregory Shimansky <[EMAIL PROTECTED]> wrote:
On Tuesday 17 October 2006 00:01 Geir Magnusson Jr. wrote: >> I tried to put some back. StackTest still doesn't work. It's hard to >> believe... so I gave up and just kept going :) >I wonder if the test or the implementation are wrong. Maybe someone who added >the test initially could know the answer.
There is nothing wrong with the stacktest test itself. The implementation
is not quite 100%complete( I think ), but has enough functionality and the test passes on Windows. On Linux, it fails. I am not sure if this is a regression, or if this ever worked. There is a JIRA issue 1786. In summary, memory protection setup for the guard page fails on the main thread(only). So the guard does not work and the overflow is not detected.
mprotect fails with an ENOMEM which is either a mapping failure or a kernel failure. mprotect() has some known flakiness it seems, as per literature. The basic implementation on Linux is sound. There are secondary design issues,but we can only get to them later after we have figured out why the guard setup fails on the main thread.