diff --git a/source/net/yacy/kelondro/index/RowCollection.java b/source/net/yacy/kelondro/index/RowCollection.java index bd467f2b8..f0ae59e56 100644 --- a/source/net/yacy/kelondro/index/RowCollection.java +++ b/source/net/yacy/kelondro/index/RowCollection.java @@ -616,8 +616,11 @@ public class RowCollection implements Sortable, Iterable, public final void sort() { if (this.sortBound == this.chunkcount) return; // this is sorted - net.yacy.cora.storage.Array.sort(this); - this.sortBound = this.chunkcount; + synchronized (this) { + if (this.sortBound == this.chunkcount) return; // check again + net.yacy.cora.storage.Array.sort(this); + this.sortBound = this.chunkcount; + } } public static class partitionthread implements Callable {