Correct uuid check according to RFC 4122

This commit is contained in:
fiaxh 2016-01-05 20:07:29 +01:00
parent abdb8bfb65
commit 62d0eebe5c
1 changed files with 1 additions and 1 deletions

View File

@ -363,7 +363,7 @@ public class Message extends AbstractEntity {
&& this.counterpart.equals(message.getCounterpart()) && this.counterpart.equals(message.getCounterpart())
&& (body.equals(otherBody) && (body.equals(otherBody)
||(message.getEncryption() == Message.ENCRYPTION_PGP ||(message.getEncryption() == Message.ENCRYPTION_PGP
&& message.getRemoteMsgId().matches("[0-9a-f]{8}-[0-9a-f]{4}-4[0-9]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}"))) ; && message.getRemoteMsgId().matches("[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}"))) ;
} else { } else {
return this.remoteMsgId == null return this.remoteMsgId == null
&& this.counterpart.equals(message.getCounterpart()) && this.counterpart.equals(message.getCounterpart())