Author: toad
Date: 2008-07-28 23:16:46 +0000 (Mon, 28 Jul 2008)
New Revision: 21456
Modified:
branches/db4o/freenet/src/freenet/client/async/InsertCompressor.java
Log:
More paranoia, prevent re-running InsertCompressor...
Modified: branches/db4o/freenet/src/freenet/client/async/InsertCompressor.java
===================================================================
--- branches/db4o/freenet/src/freenet/client/async/InsertCompressor.java
2008-07-28 23:15:02 UTC (rev 21455)
+++ branches/db4o/freenet/src/freenet/client/async/InsertCompressor.java
2008-07-28 23:16:46 UTC (rev 21456)
@@ -134,7 +134,18 @@
}, NativeThread.NORM_PRIORITY+1, false);
} else {
- inserter.onCompressed(output, null, context);
+ try {
+ inserter.onCompressed(output, null,
context);
+ } catch (Throwable t) {
+ Logger.error(this, "Caught "+t+"
running compression job", t);
+ context.jobRunner.queue(new DBJob() {
+
+ public void run(ObjectContainer
container, ClientContext context) {
+
container.delete(InsertCompressor.this);
+ }
+
+ }, NativeThread.NORM_PRIORITY+1, false);
+ }
}
} catch (final IOException e) {