Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorYann Leboulanger <asterix@lagaule.org>2004-03-04 23:56:39 +0300
committerYann Leboulanger <asterix@lagaule.org>2004-03-04 23:56:39 +0300
commitcf2c7b5037335963d114533573169fb2c1a35d9c (patch)
tree158e61b84342a2177c1114f0a998c9463705dfcf /common
parentbad3e45b97e6c6eb616a99a4dd08d691cf862d83 (diff)
log on / log off for agents
Diffstat (limited to 'common')
-rw-r--r--common/jabber.py13
1 files changed, 8 insertions, 5 deletions
diff --git a/common/jabber.py b/common/jabber.py
index bcf678489..03496e862 100644
--- a/common/jabber.py
+++ b/common/jabber.py
@@ -612,11 +612,13 @@ class Client(Connection):
def requestRegInfo(self,agent=''):
"""Requests registration info from the server.
Returns the Iq object received from the server."""
- if agent: agent = agent + '.'
+# if agent: agent = agent + '.'
self._reg_info = {}
- reg_iq = Iq(type='get', to = agent + self._host)
+# reg_iq = Iq(type='get', to = agent + self._host)
+ reg_iq = Iq(type='get', to = agent)
reg_iq.setQuery(NS_REGISTER)
- self.DEBUG("Requesting reg info from %s%s:" % (agent, self._host), DBG_NODE_IQ)
+# self.DEBUG("Requesting reg info from %s%s:" % (agent, self._host), DBG_NODE_IQ)
+ self.DEBUG("Requesting reg info from %s:" % agent, DBG_NODE_IQ)
self.DEBUG(ustr(reg_iq),DBG_NODE_IQ)
return self.SendAndWaitForResponse(reg_iq)
@@ -637,9 +639,10 @@ class Client(Connection):
def sendRegInfo(self, agent=None):
"""Sends the populated registration dictionary back to the server"""
- if agent: agent = agent + '.'
+# if agent: agent = agent + '.'
if agent is None: agent = ''
- reg_iq = Iq(to = agent + self._host, type='set')
+# reg_iq = Iq(to = agent + self._host, type='set')
+ reg_iq = Iq(to = agent, type='set')
q = reg_iq.setQuery(NS_REGISTER)
for info in self._reg_info.keys():
q.insertTag(info).putData(self._reg_info[info])