Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance
Java decentralizedintranet-searchintranet-search-enginep2pp2p-networkprivacyprivacy-protectionsearch-enginesearchenginewebweb-search-enginewebsearchwebseearch-engine
bugfix for last commit
fuchsic0f5fc51ef4d
diff --git a/source/de/anomic/data/htmlTools.java b/source/de/anomic/data/htmlTools.javaindex ad5ecd0d2..0d181040d 100644--- a/source/de/anomic/data/htmlTools.java+++ b/source/de/anomic/data/htmlTools.java@@ -43,18 +43,19 @@ public class htmlTools {*/public static String encode(String text, final String[] map, int spos, int epos) {StringBuffer sb = new StringBuffer(text.length());- search: while (spos < text.length()) {+ int textpos = 0;+ search: while (textpos < text.length()) {// find a (forward) mappingloop: for (int i = spos; i < epos; i += 2) {- if (text.charAt(spos) != map[i].charAt(0)) continue loop;+ if (text.charAt(textpos) != map[i].charAt(0)) continue loop;// found matchsb.append(map[i + 1]);- spos++;+ textpos++;continue search;}// not found matchsb.append(text.charAt(spos));- spos++;+ textpos++;}return sb.toString();