don't autonegotiate after you've disabled e2e
This commit is contained in:
parent
1b1ef68860
commit
2bb2d0132e
1 changed files with 5 additions and 0 deletions
|
@ -2646,12 +2646,17 @@ class ChatControl(ChatControlBase):
|
||||||
|
|
||||||
def _on_toggle_e2e_menuitem_activate(self, widget):
|
def _on_toggle_e2e_menuitem_activate(self, widget):
|
||||||
if self.session and self.session.enable_encryption:
|
if self.session and self.session.enable_encryption:
|
||||||
|
# e2e was enabled, disable it
|
||||||
jid = str(self.session.jid)
|
jid = str(self.session.jid)
|
||||||
thread_id = self.session.thread_id
|
thread_id = self.session.thread_id
|
||||||
|
|
||||||
self.session.terminate_e2e()
|
self.session.terminate_e2e()
|
||||||
|
|
||||||
gajim.connections[self.account].delete_session(jid, thread_id)
|
gajim.connections[self.account].delete_session(jid, thread_id)
|
||||||
|
|
||||||
|
# presumably the user had a good reason to shut it off, so
|
||||||
|
# disable autonegotiation too
|
||||||
|
self.no_autonegotiation = True
|
||||||
else:
|
else:
|
||||||
self.begin_e2e_negotiation()
|
self.begin_e2e_negotiation()
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue