[gnome-settings-daemon] datetime: Follow-up compilation fix for 15e628de



commit f3afc306d22444c6687a8c3f5ccf4e7a993c7692
Author: Bastien Nocera <hadess hadess net>
Date:   Wed Mar 16 17:56:22 2016 +0100

    datetime: Follow-up compilation fix for 15e628de
    
    priv-> was used unassigned.

 plugins/datetime/gsd-timezone-monitor.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/plugins/datetime/gsd-timezone-monitor.c b/plugins/datetime/gsd-timezone-monitor.c
index e250736..2ac8648 100644
--- a/plugins/datetime/gsd-timezone-monitor.c
+++ b/plugins/datetime/gsd-timezone-monitor.c
@@ -289,9 +289,10 @@ on_geoclue_simple_ready (GObject      *source_object,
 {
         GError *error = NULL;
         GsdTimezoneMonitorPrivate *priv;
+        GClueSimple *geoclue_simple;
 
-        priv->geoclue_simple = gclue_simple_new_finish (res, &error);
-        if (error != NULL) {
+        geoclue_simple = gclue_simple_new_finish (res, &error);
+        if (geoclue_simple == NULL) {
                 if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
                         g_warning ("Failed to connect to GeoClue2 service: %s", error->message);
                 g_error_free (error);
@@ -299,6 +300,7 @@ on_geoclue_simple_ready (GObject      *source_object,
         }
 
         priv = gsd_timezone_monitor_get_instance_private (user_data);
+        priv->geoclue_simple = geoclue_simple;
         priv->geoclue_client = gclue_simple_get_client (priv->geoclue_simple);
         gclue_client_set_distance_threshold (priv->geoclue_client,
                                              GEOCODE_LOCATION_ACCURACY_CITY);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]