blob: 841d2c2d7a18711b1bfc6c71446975b3e252f4dd [file] [log] [blame]
#include <u.h>
#include <signal.h>
#include <libc.h>
#include "9proc.h"
#undef fork
int
p9fork(void)
{
int pid;
sigset_t all, old;
sigfillset(&all);
sigprocmask(SIG_SETMASK, &all, &old);
pid = fork();
if(pid == 0){
_clearuproc();
_p9uproc(0);
}
sigprocmask(SIG_SETMASK, &old, nil);
return pid;
}