Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Side by Side Diff: fusl/src/process/vfork.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #define _GNU_SOURCE 1 #define _GNU_SOURCE
2 #include <unistd.h> 2 #include <unistd.h>
3 #include <signal.h> 3 #include <signal.h>
4 #include "syscall.h" 4 #include "syscall.h"
5 #include "libc.h" 5 #include "libc.h"
6 6
7 pid_t __vfork(void) 7 pid_t __vfork(void) {
8 { 8 /* vfork syscall cannot be made from C code */
9 » /* vfork syscall cannot be made from C code */
10 #ifdef SYS_fork 9 #ifdef SYS_fork
11 » return syscall(SYS_fork); 10 return syscall(SYS_fork);
12 #else 11 #else
13 » return syscall(SYS_clone, SIGCHLD, 0); 12 return syscall(SYS_clone, SIGCHLD, 0);
14 #endif 13 #endif
15 } 14 }
16 15
17 weak_alias(__vfork, vfork); 16 weak_alias(__vfork, vfork);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698