From: David Anderson Date: Tue, 25 Oct 2011 02:28:50 +0000 (-0700) Subject: syscall: use uintptr for Mount flags. X-Git-Tag: weekly.2011-10-25~6 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=85b9f3573e3f5a27fe0293c48cb99305f652a4bc;p=gostls13.git syscall: use uintptr for Mount flags. R=bradfitz, rsc CC=golang-dev https://golang.org/cl/5308044 --- diff --git a/src/pkg/syscall/syscall_linux.go b/src/pkg/syscall/syscall_linux.go index 50d6fa9837..e4a6561ce5 100644 --- a/src/pkg/syscall/syscall_linux.go +++ b/src/pkg/syscall/syscall_linux.go @@ -784,8 +784,8 @@ func ParseDirent(buf []byte, max int, names []string) (consumed int, count int, return origlen - len(buf), count, names } -//sys mount(source string, target string, fstype string, flags uint32, data *byte) (errno int) -func Mount(source string, target string, fstype string, flags uint32, data string) (errno int) { +//sys mount(source string, target string, fstype string, flags uintptr, data *byte) (errno int) +func Mount(source string, target string, fstype string, flags uintptr, data string) (errno int) { // Certain file systems get rather angry and EINVAL if you give // them an empty string of data, rather than NULL. if data == "" { diff --git a/src/pkg/syscall/zsyscall_linux_386.go b/src/pkg/syscall/zsyscall_linux_386.go index 35c54327d7..aed9786860 100644 --- a/src/pkg/syscall/zsyscall_linux_386.go +++ b/src/pkg/syscall/zsyscall_linux_386.go @@ -89,7 +89,7 @@ func reboot(magic1 uint, magic2 uint, cmd int, arg string) (errno int) { // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT -func mount(source string, target string, fstype string, flags uint32, data *byte) (errno int) { +func mount(source string, target string, fstype string, flags uintptr, data *byte) (errno int) { _, _, e1 := Syscall6(SYS_MOUNT, uintptr(unsafe.Pointer(StringBytePtr(source))), uintptr(unsafe.Pointer(StringBytePtr(target))), uintptr(unsafe.Pointer(StringBytePtr(fstype))), uintptr(flags), uintptr(unsafe.Pointer(data)), 0) errno = int(e1) return diff --git a/src/pkg/syscall/zsyscall_linux_amd64.go b/src/pkg/syscall/zsyscall_linux_amd64.go index 0d4ce43007..1115baa490 100644 --- a/src/pkg/syscall/zsyscall_linux_amd64.go +++ b/src/pkg/syscall/zsyscall_linux_amd64.go @@ -89,7 +89,7 @@ func reboot(magic1 uint, magic2 uint, cmd int, arg string) (errno int) { // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT -func mount(source string, target string, fstype string, flags uint32, data *byte) (errno int) { +func mount(source string, target string, fstype string, flags uintptr, data *byte) (errno int) { _, _, e1 := Syscall6(SYS_MOUNT, uintptr(unsafe.Pointer(StringBytePtr(source))), uintptr(unsafe.Pointer(StringBytePtr(target))), uintptr(unsafe.Pointer(StringBytePtr(fstype))), uintptr(flags), uintptr(unsafe.Pointer(data)), 0) errno = int(e1) return diff --git a/src/pkg/syscall/zsyscall_linux_arm.go b/src/pkg/syscall/zsyscall_linux_arm.go index a01b16ef16..0b13b37b4c 100644 --- a/src/pkg/syscall/zsyscall_linux_arm.go +++ b/src/pkg/syscall/zsyscall_linux_arm.go @@ -89,7 +89,7 @@ func reboot(magic1 uint, magic2 uint, cmd int, arg string) (errno int) { // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT -func mount(source string, target string, fstype string, flags uint32, data *byte) (errno int) { +func mount(source string, target string, fstype string, flags uintptr, data *byte) (errno int) { _, _, e1 := Syscall6(SYS_MOUNT, uintptr(unsafe.Pointer(StringBytePtr(source))), uintptr(unsafe.Pointer(StringBytePtr(target))), uintptr(unsafe.Pointer(StringBytePtr(fstype))), uintptr(flags), uintptr(unsafe.Pointer(data)), 0) errno = int(e1) return