mirror of
https://github.com/drasko/codezero.git
synced 2026-02-19 13:23:16 +01:00
Added new routines that map and check the validity of user buffers.
mmap uses this mechanism to get arguments. It needs to be tested.
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#include <tests.h>
|
||||
|
||||
int global = 0;
|
||||
extern pid_t pid;
|
||||
|
||||
int forktest(void)
|
||||
{
|
||||
@@ -18,6 +19,7 @@ int forktest(void)
|
||||
fork();
|
||||
|
||||
myid = getpid();
|
||||
pid = myid;
|
||||
if (global != 0) {
|
||||
printf("-- FAILED --\n");
|
||||
goto out;
|
||||
|
||||
Reference in New Issue
Block a user