]> Cypherpunks repositories - gostls13.git/commitdiff
syscall: rename method Flock_t.Lock to func FcntlFlock
authorBrad Fitzpatrick <bradfitz@golang.org>
Wed, 22 Jan 2014 00:27:39 +0000 (16:27 -0800)
committerBrad Fitzpatrick <bradfitz@golang.org>
Wed, 22 Jan 2014 00:27:39 +0000 (16:27 -0800)
Update #7059

R=rsc
CC=golang-codereviews
https://golang.org/cl/55370043

src/pkg/syscall/flock.go

index 5e5f8b5d175e81a6d292abbe8ec899746573b68c..62736ae9dcb4c442d00afe7f268a32f7db8a3877 100644 (file)
@@ -12,8 +12,8 @@ import "unsafe"
 // systems by flock_linux_32bit.go to be SYS_FCNTL64.
 var fcntl64Syscall uintptr = SYS_FCNTL
 
-// Lock performs a fcntl syscall for F_GETLK, F_SETLK or F_SETLKW commands.
-func (lk *Flock_t) Lock(fd uintptr, cmd int) error {
+// FcntlFlock performs a fcntl syscall for the F_GETLK, F_SETLK or F_SETLKW command.
+func FcntlFlock(fd uintptr, cmd int, lk *Flock_t) error {
        _, _, errno := Syscall(fcntl64Syscall, fd, uintptr(cmd), uintptr(unsafe.Pointer(lk)))
        if errno == 0 {
                return nil