You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by mi...@apache.org on 2012/01/03 16:28:31 UTC
svn commit: r1226821 -
/lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java
Author: mikemccand
Date: Tue Jan 3 15:28:30 2012
New Revision: 1226821
URL: http://svn.apache.org/viewvc?rev=1226821&view=rev
Log:
also delete broken segments.gen file if thread is interrupted
Modified:
lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java
Modified: lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java?rev=1226821&r1=1226820&r2=1226821&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java (original)
+++ lucene/dev/trunk/lucene/src/java/org/apache/lucene/index/SegmentInfos.java Tue Jan 3 15:28:30 2012
@@ -841,8 +841,6 @@ public final class SegmentInfos implemen
genOutput.close();
dir.sync(Collections.singleton(IndexFileNames.SEGMENTS_GEN));
}
- } catch (ThreadInterruptedException t) {
- throw t;
} catch (Throwable t) {
// It's OK if we fail to write this file since it's
// used only as one of the retry fallbacks.
@@ -852,6 +850,9 @@ public final class SegmentInfos implemen
// Ignore; this file is only used in a retry
// fallback on init.
}
+ if (t instanceof ThreadInterruptedException) {
+ throw (ThreadInterruptedException) t;
+ }
}
}