You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by jp...@apache.org on 2014/06/18 16:00:36 UTC

svn commit: r1603455 - /lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java

Author: jpountz
Date: Wed Jun 18 14:00:35 2014
New Revision: 1603455

URL: http://svn.apache.org/r1603455
Log:
LUCENE-5773: Don't account for FST.Outputs.getNoOutput which is a singleton.

Found while merging...

Modified:
    lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java

Modified: lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java?rev=1603455&r1=1603454&r2=1603455&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java (original)
+++ lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/util/fst/FST.java Wed Jun 18 14:00:35 2014
@@ -402,10 +402,10 @@ public final class FST<T> implements Acc
       for (Arc<T> arc : arcs) {
         if (arc != null) {
           size += ARC_SHALLOW_RAM_BYTES_USED;
-          if (arc.output != null) {
+          if (arc.output != null && arc.output != outputs.getNoOutput()) {
             size += outputs.ramBytesUsed(arc.output);
           }
-          if (arc.nextFinalOutput != null) {
+          if (arc.nextFinalOutput != null && arc.nextFinalOutput != outputs.getNoOutput()) {
             size += outputs.ramBytesUsed(arc.nextFinalOutput);
           }
         }