]> www.infradead.org Git - pidgin-chime.git/commitdiff
Rename method to async instead of sync
authorIgnacio Casal Quinteiro <qignacio@amazon.com>
Tue, 29 Aug 2017 07:03:23 +0000 (09:03 +0200)
committerIgnacio Casal Quinteiro <qignacio@amazon.com>
Tue, 29 Aug 2017 07:05:16 +0000 (09:05 +0200)
And add a FIXME about a missing call to the finish method.

chime-connection.c
chime-object.h
messages.c

index 3c25f3685447324d8b5a001464b16ad97cbd555f..1685b90810ebfc4c90c54517f11e395b13211edd 100644 (file)
@@ -1179,12 +1179,12 @@ static void update_last_read_cb(ChimeConnection *self, SoupMessage *msg,
 }
 
 
-void chime_connection_update_last_read_sync (ChimeConnection    *self,
-                                            ChimeObject        *obj,
-                                            const gchar        *msg_id,
-                                            GCancellable       *cancellable,
-                                            GAsyncReadyCallback callback,
-                                            gpointer            user_data)
+void chime_connection_update_last_read_async (ChimeConnection    *self,
+                                             ChimeObject        *obj,
+                                             const gchar        *msg_id,
+                                             GCancellable       *cancellable,
+                                             GAsyncReadyCallback callback,
+                                             gpointer            user_data)
 {
        g_return_if_fail(CHIME_IS_CONNECTION(self));
        ChimeConnectionPrivate *priv = CHIME_CONNECTION_GET_PRIVATE (self);
index 6c13c1acadb908af4c648dc6abd9bbba8ea80fd9..e206d46ce5d3e5bc6a923383fe3d8a1d602ec136 100644 (file)
@@ -86,7 +86,7 @@ gboolean         chime_connection_fetch_messages_finish      (ChimeConnection  *
                                                               GAsyncResult     *result,
                                                               GError          **error);
 
-void             chime_connection_update_last_read_sync      (ChimeConnection    *self,
+void             chime_connection_update_last_read_async     (ChimeConnection    *self,
                                                               ChimeObject        *obj,
                                                               const gchar        *msg_id,
                                                               GCancellable       *cancellable,
index 7018c636961879dfe6c42a55df6d153908b51a95..788a11ea5f38905a8f1275fa8308391538e0f318 100644 (file)
@@ -248,7 +248,8 @@ void chime_update_last_msg(ChimeConnection *cxn, ChimeObject *obj,
        g_free(key);
        g_free(val);
 
-       chime_connection_update_last_read_sync(cxn, obj, msg_id, NULL, NULL, NULL);
+       /* FIXME: we need to call last_read_finish to handle a possible error */
+       chime_connection_update_last_read_async(cxn, obj, msg_id, NULL, NULL, NULL);
 }
 
 /* WARE! msg_id is allocated, msg_time is const */