pidgin: f9026fae: Gadu-Gadu: function to normalize gg user...
tomkiewicz at cpw.pidgin.im
tomkiewicz at cpw.pidgin.im
Thu Oct 13 11:30:46 EDT 2011
----------------------------------------------------------------------
Revision: f9026fae7abc46af7f5f2ab7976b01b01e4c2bc8
Parent: 04e9f8380ff2e2fc411cafb524560581d9442e59
Author: tomkiewicz at cpw.pidgin.im
Date: 10/13/11 11:27:52
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/f9026fae7abc46af7f5f2ab7976b01b01e4c2bc8
Changelog:
Gadu-Gadu: function to normalize gg usernames
Changes against parent 04e9f8380ff2e2fc411cafb524560581d9442e59
patched libpurple/protocols/gg/gg.c
-------------- next part --------------
============================================================
--- libpurple/protocols/gg/gg.c 38954a8bc99a7353799992d3f0c2679877abeffb
+++ libpurple/protocols/gg/gg.c 119df2eab1b117fc995e57405acd2ae31a7cf418
@@ -2082,6 +2082,19 @@ static const char *ggp_list_icon(PurpleA
return "gadu-gadu";
}
+static const char *ggp_normalize(const PurpleAccount *account, const char *who)
+{
+ static char normalized[21]; /* maximum unsigned long long int size */
+
+ uin_t uin = ggp_str_to_uin(who);
+ if (uin <= 0)
+ return NULL;
+
+ g_snprintf(normalized, sizeof(normalized), "%u", uin);
+
+ return normalized;
+}
+
static char *ggp_status_text(PurpleBuddy *b)
{
PurpleStatus *status;
@@ -2850,7 +2863,7 @@ static PurplePluginProtocolInfo prpl_inf
NULL, /* rename_group */
NULL, /* buddy_free */
NULL, /* convo_closed */
- NULL, /* normalize */
+ ggp_normalize, /* normalize */
NULL, /* set_buddy_icon */
NULL, /* remove_group */
NULL, /* get_cb_real_name */
More information about the Commits
mailing list