0
0
Fork 0

scorch unlocks in introduceSegment's DocNumbers() error codepath

This commit is contained in:
Steve Yen 2018-01-20 17:14:07 -08:00
parent cb6391e75e
commit 34fd77709f
1 changed files with 1 additions and 0 deletions

View File

@ -117,6 +117,7 @@ func (s *Scorch) introduceSegment(next *segmentIntroduction) error {
var err error
delta, err = s.root.segment[i].segment.DocNumbers(next.ids)
if err != nil {
s.rootLock.Unlock()
next.applied <- fmt.Errorf("error computing doc numbers: %v", err)
close(next.applied)
_ = newSnapshot.DecRef()