mercurial/revlogutils/deltas.py
changeset 40606 bfbfd15d65bd
parent 40605 a32ccd32982b
child 40607 54de23400b2a
equal deleted inserted replaced
40605:a32ccd32982b 40606:bfbfd15d65bd
   255     if len(revs) <= 1:
   255     if len(revs) <= 1:
   256         yield revs
   256         yield revs
   257         return
   257         return
   258 
   258 
   259     deltachainspan = segmentspan(revlog, revs)
   259     deltachainspan = segmentspan(revlog, revs)
   260     chainpayload = sum(length(r) for r in revs)
       
   261 
   260 
   262     if deltachainspan < mingapsize:
   261     if deltachainspan < mingapsize:
   263         yield revs
   262         yield revs
   264         return
   263         return
   265 
   264 
   266     readdata = deltachainspan
   265     readdata = deltachainspan
       
   266     chainpayload = sum(length(r) for r in revs)
   267 
   267 
   268     if deltachainspan:
   268     if deltachainspan:
   269         density = chainpayload / float(deltachainspan)
   269         density = chainpayload / float(deltachainspan)
   270     else:
   270     else:
   271         density = 1.0
   271         density = 1.0