aboutsummaryrefslogtreecommitdiff
path: root/portal/tcp/portal.ml
diff options
context:
space:
mode:
authorClombrong <cromblong@egregore.fun>2025-06-26 10:16:33 +0200
committerClombrong <cromblong@egregore.fun>2025-06-26 10:16:33 +0200
commit8dfcc88b45eeee9492321b9cf6e57cfcc809f00a (patch)
tree426f78b7e1ed50b834f384a20249fe12f418ee2c /portal/tcp/portal.ml
parent5728554713343a09b2f16779ca94d84019fbbcbc (diff)
feat(portal_tcp): send XML declaration in stream negotiation
Diffstat (limited to 'portal/tcp/portal.ml')
-rw-r--r--portal/tcp/portal.ml3
1 files changed, 2 insertions, 1 deletions
diff --git a/portal/tcp/portal.ml b/portal/tcp/portal.ml
index a3fc730..76fbbc8 100644
--- a/portal/tcp/portal.ml
+++ b/portal/tcp/portal.ml
@@ -16,7 +16,8 @@ let negotiate ?from domain ((stream, push) : t) =
(("http://www.w3.org/2000/xmlns/", "xmlns"), xmlns);
(("http://www.w3.org/2000/xmlns/", "stream"),
"http://etherx.jabber.org/streams")]
- in [`Start_element
+ in [`Xml {version="1.0"; encoding=None; standalone=None};
+ `Start_element
(("http://etherx.jabber.org/streams", "stream"),
Option.fold
~none:attributes