changeset 26650:951102c642c5

Use safe function.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Thu, 23 Apr 2009 20:05:26 +0000
parents 96f82c75f1c0
children a373ce73add0
files finch/gntblist.c finch/gntnotify.c
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/finch/gntblist.c	Thu Apr 23 17:08:32 2009 +0000
+++ b/finch/gntblist.c	Thu Apr 23 20:05:26 2009 +0000
@@ -935,7 +935,7 @@
 	else if (PURPLE_BLIST_NODE_IS_GROUP(node))
 		return purple_group_get_name((PurpleGroup*)node);
 
-	snprintf(text, sizeof(text) - 1, "%s %s", status, name);
+	g_snprintf(text, sizeof(text) - 1, "%s %s", status, name);
 
 	return text;
 }
@@ -2642,7 +2642,7 @@
 		char menuid[128];
 		FinchBlistManager *manager = iter->data;
 		GntMenuItem *item = gnt_menuitem_new(_(manager->name));
-		snprintf(menuid, sizeof(menuid), "grouping-%s", manager->id);
+		g_snprintf(menuid, sizeof(menuid), "grouping-%s", manager->id);
 		gnt_menuitem_set_id(GNT_MENU_ITEM(item), menuid);
 		gnt_menu_add_item(GNT_MENU(subsub), item);
 		g_object_set_data_full(G_OBJECT(item), "grouping-id", g_strdup(manager->id), g_free);
--- a/finch/gntnotify.c	Thu Apr 23 17:08:32 2009 +0000
+++ b/finch/gntnotify.c	Thu Apr 23 20:05:26 2009 +0000
@@ -263,7 +263,7 @@
 userinfo_hash(PurpleAccount *account, const char *who)
 {
 	char key[256];
-	snprintf(key, sizeof(key), "%s - %s", purple_account_get_username(account), purple_normalize(account, who));
+	g_snprintf(key, sizeof(key), "%s - %s", purple_account_get_username(account), purple_normalize(account, who));
 	return g_utf8_strup(key, -1);
 }