aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk/empathy-location-manager.c
diff options
context:
space:
mode:
authorPierre-Luc Beaudoin <pierre-luc@pierlux.com>2009-05-28 00:49:37 +0800
committerPierre-Luc Beaudoin <pierre-luc.beaudoin@collabora.co.uk>2009-06-01 23:35:31 +0800
commitf4029062299a0f1c5f68c213bf65569e35ff44a0 (patch)
treee648df7a289948d9bbf034b5839592702bd9cc6f /libempathy-gtk/empathy-location-manager.c
parent8a4e3bef97f66bc40f9c4fb24158f0bd0226ac55 (diff)
downloadgsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar.gz
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar.bz2
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar.lz
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar.xz
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.tar.zst
gsoc2013-empathy-f4029062299a0f1c5f68c213bf65569e35ff44a0.zip
Don't call geoclue functions if the init failed
Diffstat (limited to 'libempathy-gtk/empathy-location-manager.c')
-rw-r--r--libempathy-gtk/empathy-location-manager.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/libempathy-gtk/empathy-location-manager.c b/libempathy-gtk/empathy-location-manager.c
index 9da3964ec..040bc619d 100644
--- a/libempathy-gtk/empathy-location-manager.c
+++ b/libempathy-gtk/empathy-location-manager.c
@@ -531,13 +531,19 @@ publish_cb (EmpathyConf *conf,
DEBUG ("Publish Conf changed");
priv = GET_PRIV (manager);
- if (!empathy_conf_get_bool (conf, key, &can_publish))
+
+
+ if (empathy_conf_get_bool (conf, key, &can_publish) == FALSE)
return;
- if (can_publish)
+ if (can_publish == TRUE)
{
- if (!priv->is_setup)
+ if (priv->is_setup == FALSE)
setup_geoclue (manager);
+ /* if still not setup than the init failed */
+ if (priv->is_setup == FALSE)
+ return;
+
geoclue_address_get_address_async (priv->gc_address,
initial_address_cb, manager);
geoclue_position_get_position_async (priv->gc_position,