aboutsummaryrefslogtreecommitdiff
path: root/src/timezone-geoclue.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/timezone-geoclue.c')
-rw-r--r--src/timezone-geoclue.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/timezone-geoclue.c b/src/timezone-geoclue.c
index 239ac50..f7dcf5c 100644
--- a/src/timezone-geoclue.c
+++ b/src/timezone-geoclue.c
@@ -77,6 +77,18 @@ on_address_changed (GeoclueAddress * address G_GNUC_UNUSED,
}
}
+/* The signal doesn't have the parameter for an error, so it ends up needing
+ a NULL inserted. */
+static void
+on_address_changed_sig (GeoclueAddress * address G_GNUC_UNUSED,
+ int timestamp G_GNUC_UNUSED,
+ GHashTable * addy_data,
+ GeoclueAccuracy * accuracy G_GNUC_UNUSED,
+ gpointer gself)
+{
+ return on_address_changed(address, timestamp, addy_data, accuracy, NULL, gself);
+}
+
static void
on_address_created (GeoclueMasterClient * master G_GNUC_UNUSED,
GeoclueAddress * address,
@@ -95,7 +107,7 @@ on_address_created (GeoclueMasterClient * master G_GNUC_UNUSED,
p->address = g_object_ref (address);
geoclue_address_get_address_async (address, on_address_changed, gself);
- g_signal_connect (address, "address-changed", G_CALLBACK(on_address_changed), gself);
+ g_signal_connect (address, "address-changed", G_CALLBACK(on_address_changed_sig), gself);
}
}
@@ -161,7 +173,7 @@ geo_stop (IndicatorDatetimeTimezoneGeoclue * self)
if (p->address != NULL)
{
- g_signal_handlers_disconnect_by_func (p->address, on_address_changed, self);
+ g_signal_handlers_disconnect_by_func (p->address, on_address_changed_sig, self);
g_clear_object (&p->address);
}