Mercurial > pidgin.yaz
changeset 27559:3dcc42d3cc12
Apparently, I missed a few changes for purple_debug_is_verbose().
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Sun, 12 Jul 2009 07:33:06 +0000 |
parents | 8accf7a2264c |
children | 708c7edba73b |
files | libpurple/protocols/msn/msg.c libpurple/protocols/msn/slplink.c |
diffstat | 2 files changed, 10 insertions(+), 20 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/protocols/msn/msg.c Sun Jul 12 05:06:45 2009 +0000 +++ b/libpurple/protocols/msn/msg.c Sun Jul 12 07:33:06 2009 +0000 @@ -767,8 +767,7 @@ g_string_append_printf(str, "SUB ID: %u\r\n", msg->msnslp_header.ack_sub_id); g_string_append_printf(str, "ACK Size: %" G_GUINT64_FORMAT "\r\n", msg->msnslp_header.ack_size); -#ifdef MSN_DEBUG_SLP_VERBOSE - if (body != NULL) + if (purple_debug_is_verbose() && body != NULL) { if (text_body) { @@ -792,7 +791,6 @@ g_string_append(str, "\r\n"); } } -#endif g_string_append_printf(str, "Footer: %u\r\n", msg->msnslp_footer.value); }
--- a/libpurple/protocols/msn/slplink.c Sun Jul 12 05:06:45 2009 +0000 +++ b/libpurple/protocols/msn/slplink.c Sun Jul 12 07:33:06 2009 +0000 @@ -65,9 +65,8 @@ slplink = g_new0(MsnSlpLink, 1); -#ifdef MSN_DEBUG_SLPLINK - purple_debug_info("msn", "slplink_new: slplink(%p)\n", slplink); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "slplink_new: slplink(%p)\n", slplink); slplink->session = session; slplink->slp_seq_id = rand() % 0xFFFFFF00 + 4; @@ -87,9 +86,8 @@ { MsnSession *session; -#ifdef MSN_DEBUG_SLPLINK - purple_debug_info("msn", "slplink_destroy: slplink(%p)\n", slplink); -#endif + if (purple_debug_is_verbose()) + purple_debug_info("msn", "slplink_destroy: slplink(%p)\n", slplink); g_return_if_fail(slplink != NULL); @@ -269,9 +267,8 @@ msg->msnslp_header.length = len; } -#ifdef MSN_DEBUG_SLP - msn_message_show_readable(msg, slpmsg->info, slpmsg->text_body); -#endif + if (purple_debug_is_verbose()) + msn_message_show_readable(msg, slpmsg->info, slpmsg->text_body); #ifdef MSN_DEBUG_SLP_FILES debug_msg_to_file(msg, TRUE); @@ -441,10 +438,7 @@ slpmsg->ack_id = msg->msnslp_header.id; slpmsg->ack_sub_id = msg->msnslp_header.ack_id; slpmsg->ack_size = msg->msnslp_header.total_size; - -#ifdef MSN_DEBUG_SLP slpmsg->info = "SLP ACK"; -#endif msn_slplink_send_slpmsg(slplink, slpmsg); } @@ -459,9 +453,8 @@ slpmsg = msn_slpmsg_new(slpcall->slplink); slpmsg->slpcall = slpcall; slpmsg->flags = 0x1000030; -#ifdef MSN_DEBUG_SLP slpmsg->info = "SLP FILE"; -#endif + xfer = (PurpleXfer *)slpcall->xfer; purple_xfer_start(slpcall->xfer, 0, NULL, 0); slpmsg->fp = xfer->dest_fp; @@ -496,9 +489,8 @@ guint64 offset; gsize len; -#ifdef MSN_DEBUG_SLP - msn_slpmsg_show(msg); -#endif + if (purple_debug_is_verbose()) + msn_slpmsg_show(msg); #ifdef MSN_DEBUG_SLP_FILES debug_msg_to_file(msg, FALSE);