You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by ni...@apache.org on 2017/06/22 05:25:38 UTC

[37/38] lucenenet git commit: BUG: Lucene.Net.Util.OfflineSorter: Added line to delete the output file (that existed in Lucene).

BUG: Lucene.Net.Util.OfflineSorter: Added line to delete the output file (that existed in Lucene).


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/ab75145b
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/ab75145b
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/ab75145b

Branch: refs/heads/master
Commit: ab75145b8969b475c19375fd2bcde9b66c125c36
Parents: 484f268
Author: Shad Storhaug <sh...@shadstorhaug.com>
Authored: Thu Jun 22 01:33:24 2017 +0700
Committer: Shad Storhaug <sh...@shadstorhaug.com>
Committed: Thu Jun 22 01:33:24 2017 +0700

----------------------------------------------------------------------
 src/Lucene.Net/Util/OfflineSorter.cs | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/ab75145b/src/Lucene.Net/Util/OfflineSorter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net/Util/OfflineSorter.cs b/src/Lucene.Net/Util/OfflineSorter.cs
index 91dc2c0..e7ccb95 100644
--- a/src/Lucene.Net/Util/OfflineSorter.cs
+++ b/src/Lucene.Net/Util/OfflineSorter.cs
@@ -251,9 +251,7 @@ namespace Lucene.Net.Util
         {
             sortInfo = new SortInfo(this) { TotalTime = Environment.TickCount };
 
-            // LUCENENET NOTE: Can't do this because another thread could recreate the file before we are done here.
-            // and cause this to bomb. We use the existence of the file as an indicator that we are done using it.
-            //output.Delete(); // LUCENENET TODO: BUG: Put this back in (we now have thread-safe file creation, so this should be like the original).
+            output.Delete();
 
             var merges = new List<FileInfo>();
             bool success2 = false;