Get chat to work again
This commit is contained in:
parent
5f628f1a4f
commit
fd6367007a
@ -589,6 +589,8 @@ class PresenceService(object):
|
||||
# Use random currently unassigned multicast address
|
||||
address = u"232.%d.%d.%d" % (random.randint(0, 254), random.randint(1, 254),
|
||||
random.randint(1, 254))
|
||||
properties['address'] = address
|
||||
properties['port'] = port
|
||||
if port and port != -1 and (type(port) != type(1) or port <= 1024 or port >= 65535):
|
||||
raise ValueError("port must be a number between 1024 and 65535")
|
||||
|
||||
|
@ -13,7 +13,7 @@ class GroupChat(Chat):
|
||||
def _setup_stream(self, service):
|
||||
self._group_stream = Stream.new_from_service(service)
|
||||
self._group_stream.set_data_listener(self._group_recv_message)
|
||||
self._stream_writer = self._group_stream.new_writer(service)
|
||||
self._stream_writer = self._group_stream.new_writer()
|
||||
|
||||
def _group_recv_message(self, address, msg):
|
||||
logging.debug('Group chat received from %s message %s' % (address, msg))
|
||||
|
Loading…
Reference in New Issue
Block a user