aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2017-12-04 16:50:15 +0100
committerDaniel Gultsch <daniel@gultsch.de>2017-12-04 16:50:15 +0100
commit9869310699377b9d87c504736542c4f8e11e1765 (patch)
tree3bd26dc4d093f853c7866a0f124c9cd780718d01
parent95553750a34dd664f6c9fc94289866ff0144792b (diff)
avoid some false positive quotes
-rw-r--r--src/main/java/eu/siacs/conversations/utils/UIHelper.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/main/java/eu/siacs/conversations/utils/UIHelper.java b/src/main/java/eu/siacs/conversations/utils/UIHelper.java
index b24b809..d255fd3 100644
--- a/src/main/java/eu/siacs/conversations/utils/UIHelper.java
+++ b/src/main/java/eu/siacs/conversations/utils/UIHelper.java
@@ -9,7 +9,6 @@ import android.widget.PopupMenu;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.math.BigInteger;
-import java.nio.ByteBuffer;
import java.security.MessageDigest;
import java.util.Arrays;
import java.util.Calendar;
@@ -313,16 +312,16 @@ public class UIHelper {
final char first = body.charAt(pos +1);
return first == ';'
|| first == ':'
- || smallerThanBeforeWhitespace(body,pos+1);
+ || closingBeforeWhitespace(body,pos+1);
}
}
- private static boolean smallerThanBeforeWhitespace(CharSequence body, int pos) {
+ private static boolean closingBeforeWhitespace(CharSequence body, int pos) {
for(int i = pos; i < body.length(); ++i) {
final char c = body.charAt(i);
if (Character.isWhitespace(c)) {
return false;
- } else if (c == '<') {
+ } else if (c == '<' || c == '>') {
return body.length() == i + 1 || Character.isWhitespace(body.charAt(i + 1));
}
}