This is an automated email from the ASF dual-hosted git repository.

jianliangqi pushed a commit to branch clucene-2.0
in repository https://gitbox.apache.org/repos/asf/doris-thirdparty.git


The following commit(s) were added to refs/heads/clucene-2.0 by this push:
     new c259b8b3 Revert "[fix](compile) fix clucene-2.0 compile error (#149)" 
(#150)
c259b8b3 is described below

commit c259b8b311f6b82f35f0949db967df588c23a745
Author: qiye <jianliang5...@gmail.com>
AuthorDate: Thu Dec 14 16:24:06 2023 +0800

    Revert "[fix](compile) fix clucene-2.0 compile error (#149)" (#150)
    
    This reverts commit c5e27ad6cd03dcbbb9d3c41ff6a5dfb05d05d33b.
---
 src/core/CLucene/index/TermInfosWriter.cpp | 16 ++++------------
 src/core/CLucene/index/_TermInfosWriter.h  |  3 +--
 2 files changed, 5 insertions(+), 14 deletions(-)

diff --git a/src/core/CLucene/index/TermInfosWriter.cpp 
b/src/core/CLucene/index/TermInfosWriter.cpp
index d22f04c5..b6a45d7d 100644
--- a/src/core/CLucene/index/TermInfosWriter.cpp
+++ b/src/core/CLucene/index/TermInfosWriter.cpp
@@ -410,19 +410,11 @@ void TermInfosWriter::close() {
     //Func - Closes the TermInfosWriter
     //Pre  - true
     //Post - The TermInfosWriter has been closed
+
     if (output) {
-        if (FORMAT == -4) {
-            output->writeLong(size);
-            if (!isIndex) {
-                other->tisSize = size;
-            } else {
-                output->writeLong(tisSize);
-            }
-        } else {
-            //write size at start
-            //output->seek(4);          // write size after format
-            output->writeLong(size);// do not seek now, directly write size at 
file footer
-        }
+        //write size at start
+        //output->seek(4);          // write size after format
+        output->writeLong(size);// do not seek now, directly write size at 
file footer
         output->close();
         _CLDELETE(output);
 
diff --git a/src/core/CLucene/index/_TermInfosWriter.h 
b/src/core/CLucene/index/_TermInfosWriter.h
index b2063f81..3acc2abe 100644
--- a/src/core/CLucene/index/_TermInfosWriter.h
+++ b/src/core/CLucene/index/_TermInfosWriter.h
@@ -73,8 +73,7 @@ private:
     FieldInfos *fieldInfos;
     CL_NS(store)::IndexOutput *output;
     TermInfo *lastTi;
-    int64_t size = 0;
-    int64_t tisSize = 0;
+    int64_t size;
 
     int64_t lastIndexPointer;
     bool isIndex;


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to