This commit is contained in:
Chris Lu
2020-08-17 11:12:10 -07:00
parent 4ccfdaeb4d
commit 9d46c7bc78
3 changed files with 4 additions and 4 deletions

View File

@@ -185,7 +185,7 @@ func (c *ContinuousIntervals) removeList(target *IntervalLinkedList) {
}
func (c *ContinuousIntervals) ReadData(data []byte, startOffset int64) (maxStop int64) {
func (c *ContinuousIntervals) ReadDataAt(data []byte, startOffset int64) (maxStop int64) {
for _, list := range c.lists {
start := max(startOffset, list.Offset())
stop := min(startOffset+int64(len(data)), list.Offset()+list.Size())