mirror of
https://github.com/walles/moar.git
synced 2024-11-30 02:34:13 +03:00
Don't divide by zero
This commit is contained in:
parent
ee35c6b166
commit
856574c289
@ -60,7 +60,7 @@ func (p *Pager) findFirstHit(startPosition linenumbers.LineNumber, beforePositio
|
||||
}
|
||||
|
||||
if linesCount < chunkCount {
|
||||
chunkCount = 0
|
||||
chunkCount = 1
|
||||
}
|
||||
chunkSize := linesCount / chunkCount
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user