You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by us...@apache.org on 2015/02/04 10:20:41 UTC

svn commit: r1657033 - /lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java

Author: uschindler
Date: Wed Feb  4 09:20:41 2015
New Revision: 1657033

URL: http://svn.apache.org/r1657033
Log:
Remove bogus comment.

Modified:
    lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java

Modified: lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java?rev=1657033&r1=1657032&r2=1657033&view=diff
==============================================================================
--- lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java (original)
+++ lucene/dev/branches/lucene_solr_4_10/lucene/core/src/java/org/apache/lucene/store/FSDirectory.java Wed Feb  4 09:20:41 2015
@@ -124,11 +124,6 @@ public abstract class FSDirectory extend
   protected final Set<String> staleFiles = synchronizedSet(new HashSet<String>()); // Files written, but not yet sync'ed
   private int chunkSize = DEFAULT_READ_CHUNK_SIZE;
 
-  // returns the canonical version of the directory, creating it if it doesn't exist.
-  private static File getCanonicalPath(File file) throws IOException {
-    return new File(file.getCanonicalPath());
-  }
-
   /** Create a new FSDirectory for the named location (ctor for subclasses).
    * @param path the path of the directory
    * @param lockFactory the lock factory to use, or null for the default
@@ -140,7 +135,7 @@ public abstract class FSDirectory extend
     if (lockFactory == null) {
       lockFactory = new NativeFSLockFactory();
     }
-    directory = getCanonicalPath(path);
+    directory = path.getCanonicalFile();
 
     if (directory.exists() && !directory.isDirectory())
       throw new NoSuchDirectoryException("file '" + directory + "' exists but is not a directory");