You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by ar...@apache.org on 2007/08/21 05:02:11 UTC

svn commit: r567920 - /incubator/lucene.net/trunk/C#/src/Lucene.Net/Store/FSDirectory.cs

Author: aroush
Date: Mon Aug 20 20:02:11 2007
New Revision: 567920

URL: http://svn.apache.org/viewvc?rev=567920&view=rev
Log:
Fix: LUCENENET-75 "FSDirectory does not correctly handle directory cache "DIRECTORIES""

Modified:
    incubator/lucene.net/trunk/C#/src/Lucene.Net/Store/FSDirectory.cs

Modified: incubator/lucene.net/trunk/C#/src/Lucene.Net/Store/FSDirectory.cs
URL: http://svn.apache.org/viewvc/incubator/lucene.net/trunk/C%23/src/Lucene.Net/Store/FSDirectory.cs?rev=567920&r1=567919&r2=567920&view=diff
==============================================================================
--- incubator/lucene.net/trunk/C#/src/Lucene.Net/Store/FSDirectory.cs (original)
+++ incubator/lucene.net/trunk/C#/src/Lucene.Net/Store/FSDirectory.cs Mon Aug 20 20:02:11 2007
@@ -172,7 +172,7 @@
 			FSDirectory dir;
 			lock (DIRECTORIES.SyncRoot)
 			{
-				dir = (FSDirectory) DIRECTORIES[file];
+				dir = (FSDirectory) DIRECTORIES[file.FullName];
 				if (dir == null)
 				{
 					try
@@ -184,7 +184,7 @@
 						throw new System.SystemException("cannot load FSDirectory class: " + e.ToString(), e);
 					}
 					dir.Init(file, lockFactory);
-					DIRECTORIES[file] = dir;
+					DIRECTORIES[file.FullName] = dir;
 				}
 				else
 				{
@@ -644,7 +644,7 @@
 				{
 					lock (DIRECTORIES.SyncRoot)
 					{
-						DIRECTORIES.Remove(directory);
+						DIRECTORIES.Remove(directory.FullName);
 					}
 				}
 			}