Skip to content

Commit

Permalink
Merge pull request #1067 from paulfariello/hotfix/omemo-policy
Browse files Browse the repository at this point in the history
Always follow OMEMO policy
  • Loading branch information
jubalh committed Apr 17, 2019
2 parents 3d3eabb + db55e01 commit 4403e66
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/event/server_events.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,13 @@ sv_ev_incoming_message(char *barejid, char *resource, char *message, char *pgp_m
ProfWin *window = wins_new_chat(barejid);
chatwin = (ProfChatWin*)window;
new_win = TRUE;

#ifdef HAVE_OMEMO
if (omemo_automatic_start(barejid)) {
omemo_start_session(barejid);
chatwin->is_omemo = TRUE;
}
#endif
}

// OTR suported, PGP supported, OMEMO unsupported
Expand Down Expand Up @@ -657,6 +664,13 @@ sv_ev_incoming_carbon(char *barejid, char *resource, char *message, char *pgp_me
ProfWin *window = wins_new_chat(barejid);
chatwin = (ProfChatWin*)window;
new_win = TRUE;

#ifdef HAVE_OMEMO
if (omemo_automatic_start(barejid)) {
omemo_start_session(barejid);
chatwin->is_omemo = TRUE;
}
#endif
}

#ifdef HAVE_LIBGPGME
Expand Down

0 comments on commit 4403e66

Please sign in to comment.