aboutsummaryrefslogtreecommitdiff
path: root/src/mm-iface-modem-time.c
diff options
context:
space:
mode:
authorBen Chan <benchan@chromium.org>2017-07-17 18:11:00 -0700
committerAleksander Morgado <aleksander@aleksander.es>2017-07-18 10:33:00 +0200
commitd25e6bdfaa9d4116db91a6b134a13d6319192954 (patch)
treed20aa6fcae1bd7896f5c4a370da67feccd8fb812 /src/mm-iface-modem-time.c
parent0657914ebbe387a4bb356303086fe0f354d88756 (diff)
iface-modem-time: fix update_network_timezone to use g_task_report_new_error
Commit 7c5f308af ("iface-modem-time: port update_network_timezone to use GTask") ported most of the update_network_timezone code to use GTask, but missed a g_simple_async_report_error_in_idle call, which could potentially lead to an incorrect G_TASK cast.
Diffstat (limited to 'src/mm-iface-modem-time.c')
-rw-r--r--src/mm-iface-modem-time.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/mm-iface-modem-time.c b/src/mm-iface-modem-time.c
index 41ca2f0e..f0c1fea6 100644
--- a/src/mm-iface-modem-time.c
+++ b/src/mm-iface-modem-time.c
@@ -327,12 +327,13 @@ update_network_timezone (MMIfaceModemTime *self,
/* If loading network timezone not supported, just finish here */
if (!MM_IFACE_MODEM_TIME_GET_INTERFACE (self)->load_network_timezone ||
!MM_IFACE_MODEM_TIME_GET_INTERFACE (self)->load_network_timezone_finish) {
- g_simple_async_report_error_in_idle (G_OBJECT (self),
- callback,
- user_data,
- MM_CORE_ERROR,
- MM_CORE_ERROR_UNSUPPORTED,
- "Loading network timezone is not supported");
+ g_task_report_new_error (self,
+ callback,
+ user_data,
+ update_network_timezone,
+ MM_CORE_ERROR,
+ MM_CORE_ERROR_UNSUPPORTED,
+ "Loading network timezone is not supported");
return;
}