From 9abf8f6869bc35c76bdfa86416012d4e7f0dda78 Mon Sep 17 00:00:00 2001 From: fiaxh Date: Fri, 24 Apr 2026 11:09:10 +0200 Subject: Add support for Sasl2 + Bind2 --- xmpp-vala/src/core/xmpp_stream.vala | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'xmpp-vala/src/core/xmpp_stream.vala') diff --git a/xmpp-vala/src/core/xmpp_stream.vala b/xmpp-vala/src/core/xmpp_stream.vala index 54433b67..7b05a26e 100644 --- a/xmpp-vala/src/core/xmpp_stream.vala +++ b/xmpp-vala/src/core/xmpp_stream.vala @@ -22,6 +22,7 @@ public abstract class Xmpp.XmppStream : Object { public XmppLog log = new XmppLog(); public bool negotiation_complete { get; set; default=false; } + public bool expect_further_negotiation_stanzas = false; protected bool non_negotiation_modules_attached = false; protected bool setup_needed = false; protected bool disconnected = false; @@ -99,6 +100,8 @@ public abstract class Xmpp.XmppStream : Object { public async void loop() throws IOError { while (true) { + expect_further_negotiation_stanzas = false; + if (setup_needed) { yield setup(); } @@ -112,7 +115,7 @@ public abstract class Xmpp.XmppStream : Object { yield handle_stanza(node); - if (!non_negotiation_modules_attached && negotiation_modules_done()) { + if (!expect_further_negotiation_stanzas && !non_negotiation_modules_attached && negotiation_modules_done()) { attach_non_negotation_modules(); non_negotiation_modules_attached = true; if (!negotiation_complete) { -- cgit v1.3