From 2f4b1734e945b27d54da1cf7cdd0226bd06f07d9 Mon Sep 17 00:00:00 2001 From: Michael Vetter Date: Mon, 29 Jun 2020 15:14:55 +0200 Subject: [PATCH] Dont allow starting a PGP session while in an OMEMO session --- src/command/cmd_funcs.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/command/cmd_funcs.c b/src/command/cmd_funcs.c index d184e56e..6213ba88 100644 --- a/src/command/cmd_funcs.c +++ b/src/command/cmd_funcs.c @@ -7355,6 +7355,11 @@ cmd_pgp(ProfWin *window, const char *const command, gchar **args) return TRUE; } + if (chatwin->is_omemo) { + win_println(window, THEME_DEFAULT, "!", "You must disable OMEMO before starting an PGP encrypted session."); + return TRUE; + } + ProfAccount *account = accounts_get_account(session_get_account_name()); char *err_str = NULL; if (!p_gpg_valid_key(account->pgp_keyid, &err_str)) {