[geocode-glib] Set the cancellable to check on each GSimpleAsyncResult
- From: Giovanni Campagna <gcampagna src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geocode-glib] Set the cancellable to check on each GSimpleAsyncResult
- Date: Wed, 18 Jun 2014 20:14:52 +0000 (UTC)
commit 6fa239b5aba73d135432410250449bd351993eb6
Author: Giovanni Campagna <gcampagna src gnome org>
Date: Wed Jun 18 21:59:31 2014 +0200
Set the cancellable to check on each GSimpleAsyncResult
This provides the expected semantics that cancelling an async call
trumps on any successful result or previous error.
https://bugzilla.gnome.org/show_bug.cgi?id=731880
geocode-glib/geocode-forward.c | 1 +
geocode-glib/geocode-reverse.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/geocode-glib/geocode-forward.c b/geocode-glib/geocode-forward.c
index 4256fe8..b7e3b56 100644
--- a/geocode-glib/geocode-forward.c
+++ b/geocode-glib/geocode-forward.c
@@ -540,6 +540,7 @@ geocode_forward_search_async (GeocodeForward *forward,
callback,
user_data,
geocode_forward_search_async);
+ g_simple_async_result_set_check_cancellable (simple, cancellable);
query = get_search_query_for_params (forward, &error);
if (!query) {
diff --git a/geocode-glib/geocode-reverse.c b/geocode-glib/geocode-reverse.c
index ea372bf..3f94478 100644
--- a/geocode-glib/geocode-reverse.c
+++ b/geocode-glib/geocode-reverse.c
@@ -412,6 +412,7 @@ geocode_reverse_resolve_async (GeocodeReverse *object,
callback,
user_data,
geocode_reverse_resolve_async);
+ g_simple_async_result_set_check_cancellable (simple, cancellable);
query = get_resolve_query_for_params (object->priv->ht);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]