pidgin/pidgin

Inline zephyr_resubscribe

2021-01-14, Arkadiy Illarionov
153098577f8c
Parents d036174d9e22
Children 09fc97ff0b52
Inline zephyr_resubscribe

It's used once and return value wasn't utilized.

Testing Done:
Compile.

Reviewed at https://reviews.imfreedom.org/r/426/
--- a/libpurple/protocols/zephyr/zephyr.c Thu Jan 14 07:41:45 2021 -0600
+++ b/libpurple/protocols/zephyr/zephyr.c Thu Jan 14 20:31:40 2021 -0600
@@ -2407,26 +2407,18 @@
}
-static int zephyr_resubscribe(PurpleConnection *gc)
+/* Resubscribe to the in-memory list of subscriptions and also unsubscriptions */
+static void
+zephyr_action_resubscribe(PurpleProtocolAction *action)
{
- /* Resubscribe to the in-memory list of subscriptions and also
- unsubscriptions*/
- zephyr_account *zephyr = purple_connection_get_protocol_data(gc);
+ zephyr_account *zephyr = purple_connection_get_protocol_data(action->connection);
+
for (GSList *s = zephyr->subscrips; s; s = s->next) {
zephyr_triple *zt = s->data;
/* XXX We really should care if this fails */
zephyr->subscribe_to(zephyr, zt->class, zt->instance, zt->recipient);
}
/* XXX handle unsubscriptions */
- return 1;
-}
-
-
-static void zephyr_action_resubscribe(PurpleProtocolAction *action)
-{
-
- PurpleConnection *gc = action->connection;
- zephyr_resubscribe(gc);
}