diff libpurple/protocols/oscar/oscar_data.c @ 30904:91d3b40a2f70

No need to clutter the debug log with dozens of lines when the information can fit on one, increasing readability.
author ivan.komarov@soc.pidgin.im
date Fri, 05 Nov 2010 00:37:23 +0000
parents 5661f30d1b8e
children 8d6630912021
line wrap: on
line diff
--- a/libpurple/protocols/oscar/oscar_data.c	Thu Nov 04 23:38:20 2010 +0000
+++ b/libpurple/protocols/oscar/oscar_data.c	Fri Nov 05 00:37:23 2010 +0000
@@ -37,6 +37,8 @@
 oscar_data_new(void)
 {
 	OscarData *od;
+	aim_module_t *cur;
+	GString *msg;
 
 	od = g_new0(OscarData, 1);
 
@@ -70,6 +72,20 @@
 	aim__registermodule(od, auth_modfirst);
 	aim__registermodule(od, email_modfirst);
 
+	msg = g_string_new("Registered modules: ");
+	for (cur = od->modlistv; cur; cur = cur->next) {
+		g_string_append_printf(
+			msg,
+			"%s (family=0x%04x, version=0x%04x, toolid=0x%04x, toolversion=0x%04x), ",
+			cur->name,
+			cur->family,
+			cur->version,
+			cur->toolid,
+			cur->toolversion);
+	}
+	purple_debug_misc("oscar", "%s\n", msg->str);
+	g_string_free(msg, TRUE);
+
 	return od;
 }
 
@@ -118,8 +134,6 @@
 {
 	SnacHandler *snac_handler;
 
-	purple_debug_misc("oscar", "Adding handler for %04x/%04x\n", family, subtype);
-
 	snac_handler = g_new0(SnacHandler, 1);
 
 	snac_handler->family = family;