summaryrefslogtreecommitdiff
path: root/src/pkg/syscall/zsyscall_linux_amd64.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/pkg/syscall/zsyscall_linux_amd64.go')
-rw-r--r--src/pkg/syscall/zsyscall_linux_amd64.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/pkg/syscall/zsyscall_linux_amd64.go b/src/pkg/syscall/zsyscall_linux_amd64.go
index c5daf0d9a..f16cf0a24 100644
--- a/src/pkg/syscall/zsyscall_linux_amd64.go
+++ b/src/pkg/syscall/zsyscall_linux_amd64.go
@@ -12,6 +12,13 @@ func open(path string, mode int, perm int) (fd int, errno int) {
return
}
+func openat(dirfd int, path string, flags int, mode int) (fd int, errno int) {
+ r0, _, e1 := Syscall6(SYS_OPENAT, uintptr(dirfd), uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), uintptr(mode), 0, 0)
+ fd = int(r0)
+ errno = int(e1)
+ return
+}
+
func pipe(p *[2]_C_int) (errno int) {
_, _, e1 := Syscall(SYS_PIPE, uintptr(unsafe.Pointer(p)), 0, 0)
errno = int(e1)
@@ -321,13 +328,6 @@ func Nanosleep(time *Timespec, leftover *Timespec) (errno int) {
return
}
-func Openat(dirfd int, path string, flags int, mode int) (fd int, errno int) {
- r0, _, e1 := Syscall6(SYS_OPENAT, uintptr(dirfd), uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), uintptr(mode), 0, 0)
- fd = int(r0)
- errno = int(e1)
- return
-}
-
func Pause() (errno int) {
_, _, e1 := Syscall(SYS_PAUSE, 0, 0, 0)
errno = int(e1)