forked from mirror/monocles_chat_clean
When receiving, add mock session if none exists
We need a session object in order to build a session from a PreKeyWhisperMessage, so add an empty one when none exists on receiving a message. Warning: this will break right now if the session can not be constructed from the received message.There will be an invalid session which will break if we try to send using it.
This commit is contained in:
parent
7069a5ba2f
commit
4ac3462a14
1 changed files with 1 additions and 1 deletions
|
@ -904,7 +904,7 @@ public class AxolotlService {
|
||||||
Log.d(Config.LOGTAG, "No axolotl session found while parsing received message " + message);
|
Log.d(Config.LOGTAG, "No axolotl session found while parsing received message " + message);
|
||||||
// TODO: handle this properly
|
// TODO: handle this properly
|
||||||
session = new XmppAxolotlSession(axolotlStore, senderAddress);
|
session = new XmppAxolotlSession(axolotlStore, senderAddress);
|
||||||
|
sessions.put(senderAddress,session);
|
||||||
}
|
}
|
||||||
|
|
||||||
for(XmppAxolotlMessage.XmppAxolotlMessageHeader header : message.getHeaders()) {
|
for(XmppAxolotlMessage.XmppAxolotlMessageHeader header : message.getHeaders()) {
|
||||||
|
|
Loading…
Reference in a new issue