1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 05:47:35 +00:00

LibC: Add vfork() as a simple wrapper around fork()

I don't know if we should implement optimized vfork(). I'm adding it
here since SDL2 uses it.
This commit is contained in:
Andreas Kling 2021-03-28 00:01:51 +01:00
parent 17b7779271
commit c91bb72964
2 changed files with 6 additions and 0 deletions

View file

@ -89,6 +89,11 @@ pid_t fork()
__RETURN_WITH_ERRNO(rc, rc, -1);
}
pid_t vfork()
{
return fork();
}
int execv(const char* path, char* const argv[])
{
return execve(path, argv, environ);

View file

@ -64,6 +64,7 @@ int gettid();
int donate(int tid);
int getpagesize();
pid_t fork();
pid_t vfork();
int execv(const char* path, char* const argv[]);
int execve(const char* filename, char* const argv[], char* const envp[]);
int execvpe(const char* filename, char* const argv[], char* const envp[]);