Patch Set 1: Abandoned

I can not repeat my problem. The problem was repeatable until I tested this change, but not anymore. 

My repo had ~150k files, but this works quite well now, even
without this patch.