summaryrefslogtreecommitdiff
path: root/src/bytestream-factory.c
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2009-11-26 13:50:23 +0000
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2009-11-26 17:13:31 +0000
commitbe8dbdc514ce479c4604e346206613790dba3011 (patch)
tree0ccb34bf881cce0956cf0a7135d003d95acbae15 /src/bytestream-factory.c
parenta5bdc7e1b21eb264a449c4c053831b1ec7bedf14 (diff)
downloadtelepathy-gabble-be8dbdc514ce479c4604e346206613790dba3011.tar.gz
fd.o#21151: Don't query SOCKS5 proxies when we are connected
We should query the SOCKS5 proxies only when we'll actually need them. Export the query method so other components will be able to start the querying process when needed.
Diffstat (limited to 'src/bytestream-factory.c')
-rw-r--r--src/bytestream-factory.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/bytestream-factory.c b/src/bytestream-factory.c
index 4336aa48c..728d2a414 100644
--- a/src/bytestream-factory.c
+++ b/src/bytestream-factory.c
@@ -297,8 +297,6 @@ disco_item_found_cb (GabbleDisco *disco,
send_proxy_query (self, item->jid, FALSE);
}
-static void query_socks5_proxies (GabbleBytestreamFactory *self);
-
static gboolean
socks5_proxies_timeout_cb (gpointer data)
{
@@ -316,13 +314,14 @@ socks5_proxies_timeout_cb (gpointer data)
return FALSE;
}
- query_socks5_proxies (self);
+ gabble_bytestream_factory_query_socks5_proxies (self);
return FALSE;
}
-static void
-query_socks5_proxies (GabbleBytestreamFactory *self)
+/* ask to the factory to try to find more proxies if needed */
+void
+gabble_bytestream_factory_query_socks5_proxies (GabbleBytestreamFactory *self)
{
GabbleBytestreamFactoryPrivate *priv = GABBLE_BYTESTREAM_FACTORY_GET_PRIVATE (
self);
@@ -422,8 +421,6 @@ conn_status_changed_cb (GabbleConnection *conn,
priv->socks5_potential_proxies = randomize_g_slist (
priv->socks5_potential_proxies);
- query_socks5_proxies (self);
-
g_strfreev (jids);
}
}