func (t Tree) Walk(callback TreeWalkCallback) error { err := C._go_git_treewalk( t.ptr, C.GIT_TREEWALK_PRE, unsafe.Pointer(&callback), ) if err < 0 { return LastError() } return nil }
func (t Tree) Walk(callback TreeWalkCallback) error { runtime.LockOSThread() defer runtime.UnlockOSThread() err := C._go_git_treewalk( t.cast_ptr, C.GIT_TREEWALK_PRE, unsafe.Pointer(&callback), ) if err < 0 { return MakeGitError(err) } return nil }
func (t Tree) Walk(callback TreeWalkCallback) error { runtime.LockOSThread() defer runtime.UnlockOSThread() ptr := pointerHandles.Track(callback) defer pointerHandles.Untrack(ptr) err := C._go_git_treewalk( t.cast_ptr, C.GIT_TREEWALK_PRE, ptr, ) if err < 0 { return MakeGitError(err) } return nil }