mirror of
https://github.com/hermitcore/libhermit.git
synced 2025-03-30 00:00:15 +01:00
set no execution flag to protect cmdline
This commit is contained in:
parent
2686177729
commit
6ccefbba81
1 changed files with 2 additions and 1 deletions
|
@ -331,7 +331,8 @@ int page_init(void)
|
|||
|
||||
while(((size_t) cmdline + i) <= ((size_t) cmdline + cmdsize))
|
||||
{
|
||||
page_map(((size_t) cmdline + i) & PAGE_MASK, ((size_t) cmdline + i) & PAGE_MASK, 1, PG_GLOBAL|PG_RW|PG_PRESENT);
|
||||
page_map(((size_t) cmdline + i) & PAGE_MASK, ((size_t) cmdline + i) & PAGE_MASK,
|
||||
1, PG_NX|PG_GLOBAL|PG_RW|PG_PRESENT);
|
||||
i += PAGE_SIZE;
|
||||
}
|
||||
} else cmdline = 0;
|
||||
|
|
Loading…
Add table
Reference in a new issue