fix renegotiation when a message was unable to decrypt. fixes #4360.

This commit is contained in:
Brendan Taylor 2008-10-11 22:37:11 +00:00
parent 6e596e3db0
commit 8757449816
1 changed files with 5 additions and 4 deletions

View File

@ -1818,9 +1818,9 @@ class Interface:
details = _('Unable to decrypt message from ' details = _('Unable to decrypt message from '
'%s\nIt may have been tampered with.') % jid '%s\nIt may have been tampered with.') % jid
if session.control: ctrl = session.control
session.control.print_conversation_line(details, if ctrl:
'status', '', tim) ctrl.print_conversation_line(details, 'status', '', tim)
else: else:
dialogs.WarningDialog(_('Unable to decrypt message'), dialogs.WarningDialog(_('Unable to decrypt message'),
details) details)
@ -1830,7 +1830,8 @@ class Interface:
session.conn.delete_session(jid, session.thread_id) session.conn.delete_session(jid, session.thread_id)
# restart the session # restart the session
session.negotiate_e2e(False) if ctrl:
ctrl.begin_e2e_negotiation()
def handle_event_privacy_lists_received(self, account, data): def handle_event_privacy_lists_received(self, account, data):
# ('PRIVACY_LISTS_RECEIVED', account, list) # ('PRIVACY_LISTS_RECEIVED', account, list)