| ... | ... | @@ -241,12 +241,8 @@ pub const setitimer = @compileError("TODO: setitimer"); |
| 241 | 241 | // getpid |
| 242 | 242 | // pid_t getpid(void); |
| 243 | 243 | // asmlinkage long sys_getpid(void); |
| 244 | | pub fn getpid() errno.Error!pid_t { |
| 245 | | const r = syscall0(.getpid); |
| 246 | | return switch (_errno(r)) { |
| 247 | | .ok => @intCast(r), |
| 248 | | _ => |c| errno.errorFromInt(@intFromEnum(c)), |
| 249 | | }; |
| 244 | pub fn getpid() pid_t { |
| 245 | return @intCast(syscall0(.getpid)); |
| 250 | 246 | } |
| 251 | 247 | |
| 252 | 248 | // sendfile |
| ... | ... | @@ -994,12 +990,8 @@ pub const quotactl = @compileError("TODO: quotactl"); |
| 994 | 990 | // gettid |
| 995 | 991 | // pid_t gettid(void); |
| 996 | 992 | // asmlinkage long sys_gettid(void); |
| 997 | | pub fn gettid() errno.Error!pid_t { |
| 998 | | const r = syscall0(.gettid); |
| 999 | | return switch (_errno(r)) { |
| 1000 | | .ok => @intCast(r), |
| 1001 | | _ => |c| errno.errorFromInt(@intFromEnum(c)), |
| 1002 | | }; |
| 993 | pub fn gettid() pid_t { |
| 994 | return @intCast(syscall0(.gettid)); |
| 1003 | 995 | } |
| 1004 | 996 | |
| 1005 | 997 | // readahead |