From d61e2e5c59b2311ce6e518ba7cb46929a1ef8779 Mon Sep 17 00:00:00 2001 From: Gaston Dombiak Date: Tue, 13 Sep 2005 20:09:28 +0000 Subject: [PATCH] Don't include version=1.0 when using old SSL connections. SMACK-90 git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2818 b35dd754-fafc-0310-a699-88a17e54d16e --- source/org/jivesoftware/smack/PacketWriter.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/source/org/jivesoftware/smack/PacketWriter.java b/source/org/jivesoftware/smack/PacketWriter.java index fba280941..66662cb8b 100644 --- a/source/org/jivesoftware/smack/PacketWriter.java +++ b/source/org/jivesoftware/smack/PacketWriter.java @@ -283,7 +283,13 @@ class PacketWriter { stream.append(" to=\"").append(connection.serviceName).append("\""); stream.append(" xmlns=\"jabber:client\""); stream.append(" xmlns:stream=\"http://etherx.jabber.org/streams\""); - stream.append(" version=\"1.0\">"); + if (connection instanceof SSLXMPPConnection) { + // Old SSL connections should not include indicate XMPP 1.0 compliance + stream.append(">"); + } + else { + stream.append(" version=\"1.0\">"); + } writer.write(stream.toString()); writer.flush(); }