Fixed bug 105: entity was not passed through if it occurred at end of string.

This commit is contained in:
hns 2002-09-17 23:02:43 +00:00
parent 7dfdd39240
commit 75f033f6a5

View file

@ -318,7 +318,7 @@ public final class HtmlEncoder {
switch (c) {
case '&':
// check if this is an HTML entity already, in which case we pass it though unchanged
if (i < l-4 && !insideCodeTag) {
if (i < l-3 && !insideCodeTag) {
// is this a numeric entity?
if (chars[i+1] == '#' ) {
int j = i+2;