qa: rfork(RFNAMEG) on tests that are going to rfork(RFNOMNT) later

This commit is contained in:
Giacomo Tesio 2017-01-06 23:04:04 +01:00
parent 6872a8483b
commit 01562d4ddb
3 changed files with 10 additions and 0 deletions

View File

@ -23,6 +23,7 @@ main(void)
{
int pid;
rfork(RFNAMEG);
pid = getmainpid(); // this comes from exec() syscall
if(getpid() != pid){

View File

@ -24,6 +24,7 @@ main(void)
int ppid;
Waitmsg *w;
rfork(RFNAMEG);
if(rfork(RFPROC) == 0){
ppid = getmainpid(); // this comes from exec() syscall

View File

@ -28,8 +28,16 @@ main(void)
char *msg;
start = sys_remove("#c/time");
if (start == -1){
print("FAIL: start: remove #c/time: %r");
exits("FAIL");
}
sleep(1);
end = sys_remove("#c/time");
if (end == -1){
print("end: start: remove #c/time: %r");
exits("FAIL");
}
if (end <= start)
ret = 1;