vendor: Patch github.com/syncthing/notify for Go 1.11
This commit is contained in:
parent
82c9e23206
commit
500e02cdbb
6
vendor/github.com/syncthing/notify/watcher_fsevents_cgo.go
generated
vendored
6
vendor/github.com/syncthing/notify/watcher_fsevents_cgo.go
generated
vendored
@ -48,7 +48,7 @@ var wg sync.WaitGroup // used to wait until the runloop starts
|
|||||||
// started and is ready via the wg. It also serves purpose of a dummy source,
|
// started and is ready via the wg. It also serves purpose of a dummy source,
|
||||||
// thanks to it the runloop does not return as it also has at least one source
|
// thanks to it the runloop does not return as it also has at least one source
|
||||||
// registered.
|
// registered.
|
||||||
var source = C.CFRunLoopSourceCreate(nil, 0, &C.CFRunLoopSourceContext{
|
var source = C.CFRunLoopSourceCreate(refZero, 0, &C.CFRunLoopSourceContext{
|
||||||
perform: (C.CFRunLoopPerformCallBack)(C.gosource),
|
perform: (C.CFRunLoopPerformCallBack)(C.gosource),
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -166,8 +166,8 @@ func (s *stream) Start() error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
wg.Wait()
|
wg.Wait()
|
||||||
p := C.CFStringCreateWithCStringNoCopy(nil, C.CString(s.path), C.kCFStringEncodingUTF8, nil)
|
p := C.CFStringCreateWithCStringNoCopy(refZero, C.CString(s.path), C.kCFStringEncodingUTF8, refZero)
|
||||||
path := C.CFArrayCreate(nil, (*unsafe.Pointer)(unsafe.Pointer(&p)), 1, nil)
|
path := C.CFArrayCreate(refZero, (*unsafe.Pointer)(unsafe.Pointer(&p)), 1, nil)
|
||||||
ctx := C.FSEventStreamContext{}
|
ctx := C.FSEventStreamContext{}
|
||||||
ref := C.EventStreamCreate(&ctx, C.uintptr_t(s.info), path, C.FSEventStreamEventId(atomic.LoadUint64(&since)), latency, flags)
|
ref := C.EventStreamCreate(&ctx, C.uintptr_t(s.info), path, C.FSEventStreamEventId(atomic.LoadUint64(&since)), latency, flags)
|
||||||
if ref == nilstream {
|
if ref == nilstream {
|
||||||
|
|||||||
14
vendor/github.com/syncthing/notify/watcher_fsevents_go1.10.go
generated
vendored
Normal file
14
vendor/github.com/syncthing/notify/watcher_fsevents_go1.10.go
generated
vendored
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
// Copyright (c) 2018 The Notify Authors. All rights reserved.
|
||||||
|
// Use of this source code is governed by the MIT license that can be
|
||||||
|
// found in the LICENSE file.
|
||||||
|
|
||||||
|
// +build darwin,!kqueue,cgo,!go1.11
|
||||||
|
|
||||||
|
package notify
|
||||||
|
|
||||||
|
/*
|
||||||
|
#include <CoreServices/CoreServices.h>
|
||||||
|
*/
|
||||||
|
import "C"
|
||||||
|
|
||||||
|
var refZero = (*C.struct___CFAllocator)(nil)
|
||||||
9
vendor/github.com/syncthing/notify/watcher_fsevents_go1.11.go
generated
vendored
Normal file
9
vendor/github.com/syncthing/notify/watcher_fsevents_go1.11.go
generated
vendored
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
// Copyright (c) 2018 The Notify Authors. All rights reserved.
|
||||||
|
// Use of this source code is governed by the MIT license that can be
|
||||||
|
// found in the LICENSE file.
|
||||||
|
|
||||||
|
// +build darwin,!kqueue,go1.11
|
||||||
|
|
||||||
|
package notify
|
||||||
|
|
||||||
|
const refZero = 0
|
||||||
4
vendor/manifest
vendored
4
vendor/manifest
vendored
@ -411,8 +411,8 @@
|
|||||||
"importpath": "github.com/syncthing/notify",
|
"importpath": "github.com/syncthing/notify",
|
||||||
"repository": "https://github.com/syncthing/notify",
|
"repository": "https://github.com/syncthing/notify",
|
||||||
"vcs": "git",
|
"vcs": "git",
|
||||||
"revision": "cdf89c4039d13726e227d0a472053ea19de021b4",
|
"revision": "276f739c14a87f1473de6cb6aed215c843cb51a0",
|
||||||
"branch": "master",
|
"branch": "fixed",
|
||||||
"notests": true
|
"notests": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user