summaryrefslogtreecommitdiff
path: root/src/inotify/bits.go
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2015-09-08 20:40:10 -0600
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-09-08 20:40:10 -0600
commiteed575704b9277b71fb85846cb16dfa94549465c (patch)
treee3fb2dafcd92190b18c7695fb274c39e55a4ef94 /src/inotify/bits.go
parentbdfdfb549ca887340ceb5e2d0024954dc9c4cee9 (diff)
I am dumb, fix inotify bindings
Diffstat (limited to 'src/inotify/bits.go')
-rw-r--r--src/inotify/bits.go11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/inotify/bits.go b/src/inotify/bits.go
index 9162435..432933c 100644
--- a/src/inotify/bits.go
+++ b/src/inotify/bits.go
@@ -1,7 +1,5 @@
package inotify
-import "sync/atomic"
-
const (
// Flags for the parameter of InotifyInit1().
// These, oddly, appear to be 24-bit numbers.
@@ -11,15 +9,8 @@ const (
// Logically, Fd and Wd should be 'int', not 'int64', to match the OS.
// But, because there's no 'sync/atomic.SwapInt', we cast up to int64.
-type Wd int64
type Fd int64
-
-func swapFd(addr *Fd, new Fd) (old Fd) {
- return Fd(atomic.SwapInt64((*int64)(addr), int64(new)))
-}
-func loadFd(addr *Fd) Fd {
- return Fd(atomic.LoadInt64((*int64)(addr)))
-}
+type Wd int64
type Mask uint32
const (