You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by sy...@apache.org on 2016/10/02 15:02:29 UTC
[03/10] lucenenet git commit: Fixed bug in
Analysis.Compound.Hyphenation.PatternParser that didn't call the EndElement
method on empty elements.
Fixed bug in Analysis.Compound.Hyphenation.PatternParser that didn't call the EndElement method on empty elements.
Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/d85d19b5
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/d85d19b5
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/d85d19b5
Branch: refs/heads/master
Commit: d85d19b58f7e6149e48c1162bfbdfee516050a1f
Parents: 7da43ad
Author: Shad Storhaug <sh...@shadstorhaug.com>
Authored: Thu Sep 22 22:42:02 2016 +0700
Committer: Shad Storhaug <sh...@shadstorhaug.com>
Committed: Sun Oct 2 21:44:01 2016 +0700
----------------------------------------------------------------------
.../Analysis/Compound/hyphenation/PatternParser.cs | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/d85d19b5/src/Lucene.Net.Analysis.Common/Analysis/Compound/hyphenation/PatternParser.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Analysis.Common/Analysis/Compound/hyphenation/PatternParser.cs b/src/Lucene.Net.Analysis.Common/Analysis/Compound/hyphenation/PatternParser.cs
index 33e07dd..8c00d19 100644
--- a/src/Lucene.Net.Analysis.Common/Analysis/Compound/hyphenation/PatternParser.cs
+++ b/src/Lucene.Net.Analysis.Common/Analysis/Compound/hyphenation/PatternParser.cs
@@ -156,11 +156,12 @@ namespace Lucene.Net.Analysis.Compound.Hyphenation
// Element start
uri = node.NamespaceURI;
name = node.Name;
+ bool isEmptyElement = node.IsEmptyElement;
var attributes = GetAttributes(node);
raw = string.Empty; // node.ReadOuterXml(); - not used, but was messing with the node pointer
this.StartElement(uri, name, raw, attributes);
- if (node.IsEmptyElement)
+ if (isEmptyElement)
{
this.EndElement(uri, name, raw);
}