PatchworkOS  19e446b
A non-POSIX operating system.
Loading...
Searching...
No Matches
mprotect.c
Go to the documentation of this file.
1#include <stdio.h>
2#include <sys/fs.h>
3
5
6void* mprotect(void* address, size_t length, prot_t prot)
7{
8 void* result = _syscall_mprotect(address, length, prot);
9 if (result == NULL)
10 {
12 }
13 return result;
14}
static uintptr_t address
Mapped virtual address of the HPET registers.
Definition hpet.c:96
#define errno
Error number variable.
Definition errno.h:27
void * mprotect(void *address, size_t length, prot_t prot)
System call to change the protection flags of memory.
Definition mprotect.c:6
prot_t
Memory protection flags.
Definition proc.h:122
#define NULL
Pointer error value.
Definition NULL.h:25
static void * _syscall_mprotect(void *address, size_t length, prot_t prot)
Definition syscalls.h:187
static errno_t _syscall_errno(void)
Definition syscalls.h:107