[Telepathy-commits] [telepathy-gabble/master] Add a random id to the stream opening instead of assuming buggy clients
Sjoerd Simons
sjoerd.simons at collabora.co.uk
Wed Jan 7 07:17:56 PST 2009
---
tests/twisted/gabbletest.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/tests/twisted/gabbletest.py b/tests/twisted/gabbletest.py
index a8c1e83..2b42f45 100644
--- a/tests/twisted/gabbletest.py
+++ b/tests/twisted/gabbletest.py
@@ -8,6 +8,7 @@ import os
import sha
import sys
import time
+import random
import ns
import servicetest
@@ -99,7 +100,7 @@ class JabberAuthenticator(xmlstream.Authenticator):
def streamStarted(self, root=None):
if root:
- self.xmlstream.sid = root.getAttribute('id')
+ self.xmlstream.sid = '%x' % random.randint(1, sys.maxint)
self.xmlstream.sendHeader()
self.xmlstream.addOnetimeObserver(
--
1.5.6.5
More information about the Telepathy-commits
mailing list