diff options
author | Christian Schneppe <christian@pix-art.de> | 2018-01-27 21:57:40 +0100 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2018-01-27 21:57:40 +0100 |
commit | ff1b7567d122aaa22a191f0fc7a1cc270bd57a0e (patch) | |
tree | c503121bea111aaf056b138c3c4b7204f478da60 /src/main/java/de/pixart | |
parent | ced57e3f3dd6b8d952f4b9d89ea6d10b16e1441a (diff) |
allow axolotl header to be empty in empty mucs
Diffstat (limited to 'src/main/java/de/pixart')
-rw-r--r-- | src/main/java/de/pixart/messenger/crypto/axolotl/AxolotlService.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/de/pixart/messenger/crypto/axolotl/AxolotlService.java b/src/main/java/de/pixart/messenger/crypto/axolotl/AxolotlService.java index 6970109b8..6721a7975 100644 --- a/src/main/java/de/pixart/messenger/crypto/axolotl/AxolotlService.java +++ b/src/main/java/de/pixart/messenger/crypto/axolotl/AxolotlService.java @@ -1211,11 +1211,11 @@ public class AxolotlService implements OnAdvancedStreamFeaturesLoaded { } @Nullable - private boolean buildHeader(XmppAxolotlMessage axolotlMessage, Conversation conversation) { - - Set<XmppAxolotlSession> remoteSessions = findSessionsForConversation(conversation); + private boolean buildHeader(XmppAxolotlMessage axolotlMessage, Conversation c) { + Set<XmppAxolotlSession> remoteSessions = findSessionsForConversation(c); + final boolean acceptEmpty = c.getMode() == Conversation.MODE_MULTI && c.getMucOptions().getUserCount() == 0; Collection<XmppAxolotlSession> ownSessions = findOwnSessions(); - if (remoteSessions.isEmpty()) { + if (remoteSessions.isEmpty() && !acceptEmpty) { return false; } for (XmppAxolotlSession session : remoteSessions) { |