Skip to content
Snippets Groups Projects
Commit d7cefc1e authored by Alexander Cherniuk's avatar Alexander Cherniuk
Browse files

Removed trailing space

parent 4b9e7f19
No related branches found
No related tags found
No related merge requests found
...@@ -138,7 +138,7 @@ class ConnectionBytestream: ...@@ -138,7 +138,7 @@ class ConnectionBytestream:
if 'idx' in host and host['idx'] > 0: if 'idx' in host and host['idx'] > 0:
gajim.socks5queue.remove_receiver(host['idx']) gajim.socks5queue.remove_receiver(host['idx'])
gajim.socks5queue.remove_sender(host['idx']) gajim.socks5queue.remove_sender(host['idx'])
def _send_socks5_info(self, file_props): def _send_socks5_info(self, file_props):
""" """
Send iq for the present streamhosts and proxies Send iq for the present streamhosts and proxies
...@@ -150,7 +150,7 @@ class ConnectionBytestream: ...@@ -150,7 +150,7 @@ class ConnectionBytestream:
sha_str = helpers.get_auth_sha(file_props['sid'], sender, receiver) sha_str = helpers.get_auth_sha(file_props['sid'], sender, receiver)
file_props['sha_str'] = sha_str file_props['sha_str'] = sha_str
port = gajim.config.get('file_transfers_port') port = gajim.config.get('file_transfers_port')
listener = gajim.socks5queue.start_listener(port, sha_str, listener = gajim.socks5queue.start_listener(port, sha_str,
self._result_socks5_sid, file_props['sid']) self._result_socks5_sid, file_props['sid'])
...@@ -166,11 +166,11 @@ class ConnectionBytestream: ...@@ -166,11 +166,11 @@ class ConnectionBytestream:
query = iq.setTag('query', namespace=xmpp.NS_BYTESTREAM) query = iq.setTag('query', namespace=xmpp.NS_BYTESTREAM)
query.setAttr('mode', 'plain') query.setAttr('mode', 'plain')
query.setAttr('sid', file_props['sid']) query.setAttr('sid', file_props['sid'])
self._add_addiditional_streamhosts_to_query(query, file_props) self._add_addiditional_streamhosts_to_query(query, file_props)
self._add_local_ips_as_streamhosts_to_query(query, file_props) self._add_local_ips_as_streamhosts_to_query(query, file_props)
self._add_proxy_streamhosts_to_query(query, file_props) self._add_proxy_streamhosts_to_query(query, file_props)
self.connection.send(iq) self.connection.send(iq)
def _add_streamhosts_to_query(self, query, sender, port, hosts): def _add_streamhosts_to_query(self, query, sender, port, hosts):
...@@ -188,7 +188,7 @@ class ConnectionBytestream: ...@@ -188,7 +188,7 @@ class ConnectionBytestream:
for addr in socket.getaddrinfo(socket.gethostname(), None): for addr in socket.getaddrinfo(socket.gethostname(), None):
if not addr[4][0] in my_ips and not addr[4][0].startswith('127'): if not addr[4][0] in my_ips and not addr[4][0].startswith('127'):
my_ips.append(addr[4][0]) my_ips.append(addr[4][0])
sender = file_props['sender'] sender = file_props['sender']
port = gajim.config.get('file_transfers_port') port = gajim.config.get('file_transfers_port')
self._add_streamhosts_to_query(query, sender, port, my_ips) self._add_streamhosts_to_query(query, sender, port, my_ips)
...@@ -219,9 +219,9 @@ class ConnectionBytestream: ...@@ -219,9 +219,9 @@ class ConnectionBytestream:
proxyhost['port'], [proxyhost['host']]) proxyhost['port'], [proxyhost['host']])
def _get_file_transfer_proxies_from_config(self, file_props): def _get_file_transfer_proxies_from_config(self, file_props):
configured_proxies = gajim.config.get_per('accounts', self.name, configured_proxies = gajim.config.get_per('accounts', self.name,
'file_transfer_proxies') 'file_transfer_proxies')
shall_use_proxies = gajim.config.get_per('accounts', self.name, shall_use_proxies = gajim.config.get_per('accounts', self.name,
'use_ft_proxies') 'use_ft_proxies')
if shall_use_proxies and configured_proxies: if shall_use_proxies and configured_proxies:
proxyhost_dicts = [] proxyhost_dicts = []
...@@ -232,7 +232,7 @@ class ConnectionBytestream: ...@@ -232,7 +232,7 @@ class ConnectionBytestream:
if default_proxy in proxies: if default_proxy in proxies:
proxies.remove(default_proxy) proxies.remove(default_proxy)
proxies.insert(0, default_proxy) proxies.insert(0, default_proxy)
for proxy in proxies: for proxy in proxies:
(host, _port, jid) = gajim.proxy65_manager.get_proxy(proxy, self.name) (host, _port, jid) = gajim.proxy65_manager.get_proxy(proxy, self.name)
if not host: if not host:
...@@ -631,7 +631,7 @@ class ConnectionBytestream: ...@@ -631,7 +631,7 @@ class ConnectionBytestream:
file_props['error'] = -3 file_props['error'] = -3
self.dispatch('FILE_REQUEST_ERROR', (jid, file_props, '')) self.dispatch('FILE_REQUEST_ERROR', (jid, file_props, ''))
raise xmpp.NodeProcessed raise xmpp.NodeProcessed
class ConnectionBytestreamZeroconf(ConnectionBytestream): class ConnectionBytestreamZeroconf(ConnectionBytestream):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment