Skip to content

Commit

Permalink
kv: make sure each streaming response does contain a range entry (pin…
Browse files Browse the repository at this point in the history
  • Loading branch information
SunRunAway authored and sre-bot committed Oct 28, 2019
1 parent deb7700 commit 606a767
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions store/tikv/coprocessor.go
Original file line number Diff line number Diff line change
Expand Up @@ -765,6 +765,9 @@ func (worker *copIteratorWorker) handleCopStreamResult(bo *Backoffer, rpcCtx *RP
}
return worker.buildCopTasksFromRemain(bo, lastRange, task)
}
if resp.Range == nil {
return nil, errors.New("streaming response should contain a range entry")
}
lastRange = resp.Range
}
}
Expand Down

0 comments on commit 606a767

Please sign in to comment.