Mercurial > pidgin
diff libpurple/protocols/msn/msg.c @ 27432:35b6fd563056
Change all MSN_DEBUG_* messages to use the new purple_debug_is_verbose call
for runtime switching.
| author | Elliott Sales de Andrade <qulogic@pidgin.im> |
|---|---|
| date | Fri, 10 Jul 2009 00:51:31 +0000 |
| parents | 9c413bda20be |
| children | 3dcc42d3cc12 15cde23b43bc |
line wrap: on
line diff
--- a/libpurple/protocols/msn/msg.c Thu Jul 09 05:37:37 2009 +0000 +++ b/libpurple/protocols/msn/msg.c Fri Jul 10 00:51:31 2009 +0000 @@ -33,9 +33,8 @@ msg = g_new0(MsnMessage, 1); msg->type = type; -#ifdef MSN_DEBUG_MSG - purple_debug_info("msn", "message new (%p)(%d)\n", msg, type); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "message new (%p)(%d)\n", msg, type); msg->attr_table = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free); @@ -57,9 +56,8 @@ return; } -#ifdef MSN_DEBUG_MSG - purple_debug_info("msn", "message destroy (%p)\n", msg); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "message destroy (%p)\n", msg); g_free(msg->remote_user); g_free(msg->body); @@ -79,9 +77,8 @@ msg->ref_count++; -#ifdef MSN_DEBUG_MSG - purple_debug_info("msn", "message ref (%p)[%" G_GSIZE_FORMAT "]\n", msg, msg->ref_count); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "message ref (%p)[%" G_GSIZE_FORMAT "]\n", msg, msg->ref_count); return msg; } @@ -94,9 +91,8 @@ msg->ref_count--; -#ifdef MSN_DEBUG_MSG - purple_debug_info("msn", "message unref (%p)[%" G_GSIZE_FORMAT "]\n", msg, msg->ref_count); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "message unref (%p)[%" G_GSIZE_FORMAT "]\n", msg, msg->ref_count); if (msg->ref_count == 0) {
