Commit c681514a authored by mad.one@gmail.com's avatar mad.one@gmail.com
Browse files

wibble in setExecutable

parent 97c4b274
......@@ -237,6 +237,6 @@ void setExecutable (void *p, lnat len, rtsBool exec)
StgWord size = startOfLastPage - startOfFirstPage + pageSize;
if (mprotect((void*)startOfFirstPage, (size_t)size,
(exec ? PROT_EXEC : 0) | PROT_READ | PROT_WRITE) != 0) {
barf("makeExecutable: failed to protect 0x%p\n", p);
barf("setExecutable: failed to protect 0x%p\n", p);
}
}
......@@ -255,7 +255,7 @@ void setExecutable (void *p, lnat len, rtsBool exec)
exec ? PAGE_EXECUTE_READWRITE : PAGE_READWRITE,
&dwOldProtect) == 0)
{
sysErrorBelch("makeExecutable: failed to protect 0x%p; old protection: %lu\n",
sysErrorBelch("setExecutable: failed to protect 0x%p; old protection: %lu\n",
p, (unsigned long)dwOldProtect);
stg_exit(EXIT_FAILURE);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment