Fix test failure

This commit is contained in:
Michael Boulton 2020-08-14 11:11:35 +01:00
parent a2b8cf952a
commit 1e38283adb
No known key found for this signature in database
GPG Key ID: 8A62CA0BE2E0197E
1 changed files with 2 additions and 0 deletions

View File

@ -87,6 +87,8 @@ func (statusList *StatusList) ByIndex(index int) (StatusEntry, error) {
}
ptr := C.git_status_byindex(statusList.ptr, C.size_t(index))
if ptr == nil {
runtime.LockOSThread()
defer runtime.UnlockOSThread()
return StatusEntry{}, MakeGitError(C.int(ErrNotFound))
}
entry := statusEntryFromC(ptr)