From 09157254103833a153156911294f41abd78fdc46 Mon Sep 17 00:00:00 2001 From: asofold Date: Mon, 3 Sep 2012 02:46:26 +0200 Subject: [PATCH] node is a newly added node, if create == true. --- .../nocheatplus/checks/chat/analysis/ds/LookupTree.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/fr/neatmonster/nocheatplus/checks/chat/analysis/ds/LookupTree.java b/src/fr/neatmonster/nocheatplus/checks/chat/analysis/ds/LookupTree.java index 9c9da542..e0d63b4b 100644 --- a/src/fr/neatmonster/nocheatplus/checks/chat/analysis/ds/LookupTree.java +++ b/src/fr/neatmonster/nocheatplus/checks/chat/analysis/ds/LookupTree.java @@ -89,7 +89,7 @@ public class LookupTree>{ @SuppressWarnings("unchecked") public LookupEntry lookup(final List keys, final boolean create){ N insertion = root; - N leaf = null; + N node = null; int depth = 0; N current = root; final NodeFactory factory = (NodeFactory) (create ? this.factory : null); @@ -109,10 +109,10 @@ public class LookupTree>{ } } if (create || insertion.isEnd && depth == keys.size()){ - leaf = current; + node = current; if (insertion != current) current.isEnd = true; } - return new LookupEntry(leaf, insertion, depth); + return new LookupEntry(node, insertion, depth); } public void clear() {