Author: toad
Date: 2008-11-07 00:38:25 +0000 (Fri, 07 Nov 2008)
New Revision: 23371

Modified:
   trunk/freenet/src/freenet/support/io/TempBucketFactory.java
Log:
Don't close twice.


Modified: trunk/freenet/src/freenet/support/io/TempBucketFactory.java
===================================================================
--- trunk/freenet/src/freenet/support/io/TempBucketFactory.java 2008-11-07 
00:09:01 UTC (rev 23370)
+++ trunk/freenet/src/freenet/support/io/TempBucketFactory.java 2008-11-07 
00:38:25 UTC (rev 23371)
@@ -217,6 +217,7 @@
                        @Override
                        public final void close() throws IOException {
                                synchronized(TempBucket.this) {
+                                       if(closed) return;
                                        _maybeMigrateRamBucket(currentSize);
                                        os.flush();
                                        os.close();


Reply via email to