Commit e9c4f099 authored by Ian Lance Taylor's avatar Ian Lance Taylor

syscall: Make Access second argument consistently uint32.

Fixes #1377.

R=rsc, adg, r
CC=golang-dev
https://golang.org/cl/3868041
parent 3f38342e
...@@ -25,7 +25,7 @@ func Kill(pid int, signum int) (errno int) { return kill(pid, signum, 1) } ...@@ -25,7 +25,7 @@ func Kill(pid int, signum int) (errno int) { return kill(pid, signum, 1) }
/* /*
* Exposed directly * Exposed directly
*/ */
//sys Access(path string, flags int) (errno int) //sys Access(path string, mode uint32) (errno int)
//sys Adjtime(delta *Timeval, olddelta *Timeval) (errno int) //sys Adjtime(delta *Timeval, olddelta *Timeval) (errno int)
//sys Chdir(path string) (errno int) //sys Chdir(path string) (errno int)
//sys Chflags(path string, flags int) (errno int) //sys Chflags(path string, flags int) (errno int)
......
...@@ -17,7 +17,7 @@ const OS = "freebsd" ...@@ -17,7 +17,7 @@ const OS = "freebsd"
/* /*
* Exposed directly * Exposed directly
*/ */
//sys Access(path string, flags int) (errno int) //sys Access(path string, mode uint32) (errno int)
//sys Adjtime(delta *Timeval, olddelta *Timeval) (errno int) //sys Adjtime(delta *Timeval, olddelta *Timeval) (errno int)
//sys Chdir(path string) (errno int) //sys Chdir(path string) (errno int)
//sys Chflags(path string, flags int) (errno int) //sys Chflags(path string, flags int) (errno int)
......
...@@ -196,8 +196,8 @@ func kill(pid int, signum int, posix int) (errno int) { ...@@ -196,8 +196,8 @@ func kill(pid int, signum int, posix int) (errno int) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
func Access(path string, flags int) (errno int) { func Access(path string, mode uint32) (errno int) {
_, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), 0) _, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(mode), 0)
errno = int(e1) errno = int(e1)
return return
} }
......
...@@ -196,8 +196,8 @@ func kill(pid int, signum int, posix int) (errno int) { ...@@ -196,8 +196,8 @@ func kill(pid int, signum int, posix int) (errno int) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
func Access(path string, flags int) (errno int) { func Access(path string, mode uint32) (errno int) {
_, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), 0) _, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(mode), 0)
errno = int(e1) errno = int(e1)
return return
} }
......
...@@ -188,8 +188,8 @@ func fcntl(fd int, cmd int, arg int) (val int, errno int) { ...@@ -188,8 +188,8 @@ func fcntl(fd int, cmd int, arg int) (val int, errno int) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
func Access(path string, flags int) (errno int) { func Access(path string, mode uint32) (errno int) {
_, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), 0) _, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(mode), 0)
errno = int(e1) errno = int(e1)
return return
} }
......
...@@ -188,8 +188,8 @@ func fcntl(fd int, cmd int, arg int) (val int, errno int) { ...@@ -188,8 +188,8 @@ func fcntl(fd int, cmd int, arg int) (val int, errno int) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
func Access(path string, flags int) (errno int) { func Access(path string, mode uint32) (errno int) {
_, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(flags), 0) _, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(StringBytePtr(path))), uintptr(mode), 0)
errno = int(e1) errno = int(e1)
return return
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment