OLD | NEW |
1 // Copyright 2009,2010 The Go Authors. All rights reserved. | 1 // Copyright 2009,2010 The Go Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style | 2 // Use of this source code is governed by a BSD-style |
3 // license that can be found in the LICENSE file. | 3 // license that can be found in the LICENSE file. |
4 | 4 |
5 // Darwin system calls. | 5 // Darwin system calls. |
6 // This file is compiled as ordinary Go code, | 6 // This file is compiled as ordinary Go code, |
7 // but it is also input to mksyscall, | 7 // but it is also input to mksyscall, |
8 // which parses the //sys lines and generates system call stubs. | 8 // which parses the //sys lines and generates system call stubs. |
9 // Note that sometimes we use a lowercase //sys name and wrap | 9 // Note that sometimes we use a lowercase //sys name and wrap |
10 // it in our own nicer implementation, either here or in | 10 // it in our own nicer implementation, either here or in |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 func Sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
rror) { | 100 func Sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
rror) { |
101 return -1, ENOSYS | 101 return -1, ENOSYS |
102 } | 102 } |
103 | 103 |
104 /* | 104 /* |
105 * Wrapped | 105 * Wrapped |
106 */ | 106 */ |
107 | 107 |
108 //sys kill(pid int, signum int, posix int) (err error) | 108 //sys kill(pid int, signum int, posix int) (err error) |
109 | 109 |
110 func Kill(pid int, signum Signal) (err error) { return kill(pid, int(signum), 1)
} | 110 func Kill(pid int, signum Signal) (err error) { return kill(pid, int(signum)
, 1) } |
| 111 func WriteNB(fd int, p []byte) (n int, err error) { return Write(fd, p) } |
111 | 112 |
112 /* | 113 /* |
113 * Exposed directly | 114 * Exposed directly |
114 */ | 115 */ |
115 //sys Access(path string, mode uint32) (err error) | 116 //sys Access(path string, mode uint32) (err error) |
116 //sys Adjtime(delta *Timeval, olddelta *Timeval) (err error) | 117 //sys Adjtime(delta *Timeval, olddelta *Timeval) (err error) |
117 //sys Chdir(path string) (err error) | 118 //sys Chdir(path string) (err error) |
118 //sys Chflags(path string, flags int) (err error) | 119 //sys Chflags(path string, flags int) (err error) |
119 //sys Chmod(path string, mode uint32) (err error) | 120 //sys Chmod(path string, mode uint32) (err error) |
120 //sys Chown(path string, uid int, gid int) (err error) | 121 //sys Chown(path string, uid int, gid int) (err error) |
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 // Poll_nocancel | 395 // Poll_nocancel |
395 // Msgsnd_nocancel | 396 // Msgsnd_nocancel |
396 // Msgrcv_nocancel | 397 // Msgrcv_nocancel |
397 // Sem_wait_nocancel | 398 // Sem_wait_nocancel |
398 // Aio_suspend_nocancel | 399 // Aio_suspend_nocancel |
399 // __sigwait_nocancel | 400 // __sigwait_nocancel |
400 // __semwait_signal_nocancel | 401 // __semwait_signal_nocancel |
401 // __mac_mount | 402 // __mac_mount |
402 // __mac_get_mount | 403 // __mac_get_mount |
403 // __mac_getfsstat | 404 // __mac_getfsstat |
OLD | NEW |