From 6cbca1e508fa8bf338432f7dec8b63dc70293780 Mon Sep 17 00:00:00 2001 From: orbiter Date: Thu, 29 Jan 2009 16:42:01 +0000 Subject: [PATCH] extended last fix, preventing more sorts git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@5533 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- source/de/anomic/kelondro/kelondroRowCollection.java | 4 +++- source/de/anomic/server/serverClassLoader.java | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/source/de/anomic/kelondro/kelondroRowCollection.java b/source/de/anomic/kelondro/kelondroRowCollection.java index ff4e29933..a9a8e81e5 100644 --- a/source/de/anomic/kelondro/kelondroRowCollection.java +++ b/source/de/anomic/kelondro/kelondroRowCollection.java @@ -253,9 +253,11 @@ public class kelondroRowCollection implements Iterable { public synchronized final void set(final int index, final kelondroRow.Entry a) { assert (index >= 0) : "set: access with index " + index + " is below zero"; ensureSize(index + 1); + boolean sameKey = match(a.bytes(), 0, a.cellwidth(0), index); + //if (sameKey) System.out.print("$"); a.writeToArray(chunkcache, index * rowdef.objectsize); if (index >= this.chunkcount) this.chunkcount = index + 1; - if (index < this.sortBound) this.sortBound = index; + if (!sameKey && index < this.sortBound) this.sortBound = index; this.lastTimeWrote = System.currentTimeMillis(); } diff --git a/source/de/anomic/server/serverClassLoader.java b/source/de/anomic/server/serverClassLoader.java index b6011bba7..9267e053f 100644 --- a/source/de/anomic/server/serverClassLoader.java +++ b/source/de/anomic/server/serverClassLoader.java @@ -58,7 +58,7 @@ public final class serverClassLoader extends ClassLoader { // load the file from the file system byte[] b; try { - System.out.println("*** DEBUG CLASSLOADER: " + classfile + "; file " + (classfile.exists() ? "exists": "does not exist")); + //System.out.println("*** DEBUG CLASSLOADER: " + classfile + "; file " + (classfile.exists() ? "exists": "does not exist")); b = serverFileUtils.read(classfile); // make a class out of the stream c = this.defineClass(null, b, 0, b.length);