Comment by a1369209993
7 years ago
(See man (2)execve.)
int p_execve(pid_t target,char* filename,
char** argv,char** envp);
Executes a new program, specified by filename, in the context of the specified process. On success, the text, data, bss, and stack of the process specified by target are overwritten by that of the program loaded.
A target of zero specifies the current process, so p_execve(0,file,argv,envp) is equivalent to execve(file,argv,envp).
BUGS
We should probably require some kind of permission check before allowing the calling process to do this.
No comments yet
Contribute on Hacker News ↗