removed unnecessary cache flush call in backend of BufferedRecords

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@6774 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 15 years ago
parent 749ffbd642
commit 72d8e9897b

@ -54,7 +54,7 @@ public final class BufferedRecords {
/**
* flush the buffer: this shall be called before any file-based iterations
* on data structures on rescords are made
* on data structures on records are made
* @throws IOException
*/
public synchronized void flushBuffer() throws IOException {
@ -68,11 +68,10 @@ public final class BufferedRecords {
efs.put(entry.getKey().intValue(), entry.getValue(), 0);
}
buffer.clear();
efs.flushBuffer();
}
public final synchronized long size() throws IOException {
return efs == null ? 0 : efs.size(); // stuck
return efs == null ? 0 : efs.size();
}
public final File filename() {
@ -127,7 +126,7 @@ public final class BufferedRecords {
assert b.length - start >= efs.recordsize;
final byte[] bb = buffer.remove(Long.valueOf(size() - 1));
if (bb == null) {
efs.cleanLast(b, start); // stuck
efs.cleanLast(b, start);
} else {
System.arraycopy(bb, 0, b, start, efs.recordsize);
efs.cleanLast();

Loading…
Cancel
Save