From 8041d23cb16c9c032bd9e0a8008be543520d6353 Mon Sep 17 00:00:00 2001 From: Michael Date: Sat, 24 Jan 2015 16:19:58 +0100 Subject: MessageParser: fix the regex for otr query messages. --- src/main/java/eu/siacs/conversations/parser/MessageParser.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/main/java/eu/siacs/conversations/parser/MessageParser.java b/src/main/java/eu/siacs/conversations/parser/MessageParser.java index 4d102c3a..bfe081cd 100644 --- a/src/main/java/eu/siacs/conversations/parser/MessageParser.java +++ b/src/main/java/eu/siacs/conversations/parser/MessageParser.java @@ -75,7 +75,7 @@ public class MessageParser extends AbstractParser implements } updateLastseen(packet, account, true); String body = packet.getBody(); - if (body.matches("^\\?OTRv\\d*\\?")) { + if (body.matches("^\\?OTRv\\d{1,2}\\?.*")) { conversation.endOtrIfNeeded(); } if (!conversation.hasValidOtrSession()) { -- cgit v1.2.3