]> go.fuhry.dev Git - fsnotify.git/commitdiff
Mutex used on all OSs
authorChris Howey <chris@howey.me>
Thu, 7 Feb 2013 03:43:44 +0000 (21:43 -0600)
committerChris Howey <chris@howey.me>
Thu, 7 Feb 2013 03:43:44 +0000 (21:43 -0600)
fsnotify_windows.go

index a2768d1f9c6fc8060be543a7006239eb7ff812b8..e79185ff7401905f2e715e775001bd3157fbc9b8 100644 (file)
@@ -85,6 +85,7 @@ type Watcher struct {
        port          syscall.Handle    // Handle to completion port
        watches       watchMap          // Map of watches (key: i-number)
        fsnFlags      map[string]uint32 // Map of watched files to flags used for filter
+       fsnmut        sync.Mutex        // Protects access to fsnFlags.
        input         chan *input       // Inputs to the reader are sent on this channel
        internalEvent chan *FileEvent   // Events are queued on this channel
        Event         chan *FileEvent   // Events are returned on this channel