proxyclient/m1n1/utils.py: don't compact non-adjacent ranges

Signed-off-by: Pip Cet <pipcet@gmail.com>
This commit is contained in:
Pip Cet 2021-07-28 11:47:37 +00:00 committed by Hector Martin
parent 1d932888f9
commit d709b047d8

View file

@ -400,7 +400,7 @@ class RangeMap(Reloadable):
s, e, v = self.__start[pos], self.__end[pos], self.__value[pos]
if empty(v):
continue
if new_v and equal(last, v):
if new_v and equal(last, v) and s == new_e[-1] + 1:
new_e[-1] = e
else:
new_s.append(s)