diff -r 86be56b9ba46 -r fc9ed50498fb hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp --- a/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Tue Dec 09 09:55:39 2008 -0500 +++ b/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Wed Dec 10 15:14:29 2008 -0800 @@ -422,10 +422,11 @@ if (addr != last_addr && (UnguardOnExecutionViolation > 1 || os::address_is_in_vm(addr))) { - // Unguard and retry + // Set memory to RWX and retry address page_start = (address) align_size_down((intptr_t) addr, (intptr_t) page_size); - bool res = os::unguard_memory((char*) page_start, page_size); + bool res = os::protect_memory((char*) page_start, page_size, + os::MEM_PROT_RWX); if (PrintMiscellaneous && Verbose) { char buf[256];