Fix bug with receiving GV2 message for previously unknown group.

This commit is contained in:
Cody Henthorne
2022-04-22 16:07:06 -04:00
parent 1446af97a2
commit 33346d8033
2 changed files with 3 additions and 2 deletions

View File

@@ -532,7 +532,8 @@ public final class MessageContentProcessor {
throws IOException, GroupChangeBusyException
{
try {
GroupManager.updateGroupFromServer(context, groupV2.getMasterKey(), groupV2.getRevision(), content.getTimestamp(), groupV2.getSignedGroupChange());
long timestamp = groupV2.getSignedGroupChange() != null ? content.getTimestamp() : content.getTimestamp() - 1;
GroupManager.updateGroupFromServer(context, groupV2.getMasterKey(), groupV2.getRevision(), timestamp, groupV2.getSignedGroupChange());
return true;
} catch (GroupNotAMemberException e) {
warn(String.valueOf(content.getTimestamp()), "Ignoring message for a group we're not in");