| Index: src/java/org/apache/lucene/store/FileSwitchDirectory.java
|
| ===================================================================
|
| --- src/java/org/apache/lucene/store/FileSwitchDirectory.java (revision 772755)
|
| +++ src/java/org/apache/lucene/store/FileSwitchDirectory.java (working copy)
|
| @@ -84,7 +84,9 @@
|
| return name.substring(i+1, name.length()); |
| } |
| |
| - private Directory getDirectory(String name) { |
| + private Directory getDirectory(String name) throws IOException { |
| + if (primaryDir.fileExists(name)) return primaryDir; |
| + if (secondaryDir.fileExists(name)) return secondaryDir; |
| String ext = getExtension(name); |
| if (primaryExtensions.contains(ext)) { |
| return primaryDir; |