Mercurial > pidgin
changeset 28513:fa7f3426ed13
jabber: Convert to purple_debug_* convenience functions.
author | Paul Aurich <paul@darkrain42.org> |
---|---|
date | Fri, 06 Nov 2009 08:39:49 +0000 |
parents | 562fd22dbe89 |
children | 5328e205d3fb |
files | libpurple/protocols/jabber/auth.c libpurple/protocols/jabber/buddy.c libpurple/protocols/jabber/google.c libpurple/protocols/jabber/jabber.c libpurple/protocols/jabber/message.c libpurple/protocols/jabber/oob.c libpurple/protocols/jabber/si.c libpurple/protocols/jabber/useravatar.c |
diffstat | 8 files changed, 17 insertions(+), 18 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/protocols/jabber/auth.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/auth.c Fri Nov 06 08:39:49 2009 +0000 @@ -877,7 +877,7 @@ } dec_in = (char *)purple_base64_decode(enc_in, NULL); - purple_debug(PURPLE_DEBUG_MISC, "jabber", "decoded challenge (%" + purple_debug_misc("jabber", "decoded challenge (%" G_GSIZE_FORMAT "): %s\n", strlen(dec_in), dec_in); parts = parse_challenge(dec_in);
--- a/libpurple/protocols/jabber/buddy.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/buddy.c Fri Nov 06 08:39:49 2009 +0000 @@ -581,8 +581,7 @@ if (text != NULL && *text != '\0') { xmlnode *xp; - purple_debug(PURPLE_DEBUG_INFO, "jabber", - "Setting %s to '%s'\n", vc_tp->tag, text); + purple_debug_info("jabber", "Setting %s to '%s'\n", vc_tp->tag, text); if ((xp = insert_tag_to_parent_tag(vc_node, NULL, vc_tp->tag)) != NULL) {
--- a/libpurple/protocols/jabber/google.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/google.c Fri Nov 06 08:39:49 2009 +0000 @@ -910,7 +910,7 @@ xmlnode_set_attrib(iq->node, "id", id); jabber_iq_send(iq); - purple_debug(PURPLE_DEBUG_MISC, "jabber", + purple_debug_misc("jabber", "Got new mail notification. Sending request for more info\n"); iq = jabber_iq_new_query(js, JABBER_IQ_GET, "google:mail:notify"); @@ -1094,12 +1094,13 @@ jbr = l->data; if (jbr && jbr->name) { - purple_debug(PURPLE_DEBUG_MISC, "jabber", "Removing resource %s\n", jbr->name); + purple_debug_misc("jabber", "Removing resource %s\n", jbr->name); jabber_buddy_remove_resource(jb, jbr->name); } l = l->next; } } + purple_prpl_got_user_status(purple_connection_get_account(gc), who, "offline", NULL); }
--- a/libpurple/protocols/jabber/jabber.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/jabber.c Fri Nov 06 08:39:49 2009 +0000 @@ -294,8 +294,7 @@ else purple_debug_warning("jabber", "Ignoring spurious <proceed/>\n"); } else { - purple_debug(PURPLE_DEBUG_WARNING, "jabber", "Unknown packet: %s\n", - (*packet)->name); + purple_debug_warning("jabber", "Unknown packet: %s\n", (*packet)->name); } } @@ -531,7 +530,7 @@ while((len = purple_ssl_read(gsc, buf, sizeof(buf) - 1)) > 0) { gc->last_received = time(NULL); buf[len] = '\0'; - purple_debug(PURPLE_DEBUG_INFO, "jabber", "Recv (ssl)(%d): %s\n", len, buf); + purple_debug_info("jabber", "Recv (ssl)(%d): %s\n", len, buf); jabber_parser_process(js, buf, len); if(js->reinit) jabber_stream_init(js); @@ -571,7 +570,7 @@ unsigned int olen; sasl_decode(js->sasl, buf, len, &out, &olen); if (olen>0) { - purple_debug(PURPLE_DEBUG_INFO, "jabber", "RecvSASL (%u): %s\n", olen, out); + purple_debug_info("jabber", "RecvSASL (%u): %s\n", olen, out); jabber_parser_process(js,out,olen); if(js->reinit) jabber_stream_init(js); @@ -580,7 +579,7 @@ } #endif buf[len] = '\0'; - purple_debug(PURPLE_DEBUG_INFO, "jabber", "Recv (%d): %s\n", len, buf); + purple_debug_info("jabber", "Recv (%d): %s\n", len, buf); jabber_parser_process(js, buf, len); if(js->reinit) jabber_stream_init(js);
--- a/libpurple/protocols/jabber/message.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/message.c Fri Nov 06 08:39:49 2009 +0000 @@ -812,7 +812,7 @@ switch(jm->type) { case JABBER_MESSAGE_OTHER: - purple_debug(PURPLE_DEBUG_INFO, "jabber", + purple_debug_info("jabber", "Received message of unknown type: %s\n", type); /* Fall-through is intentional */ case JABBER_MESSAGE_NORMAL: @@ -1103,7 +1103,7 @@ if ((child = xmlnode_from_str(jm->xhtml, -1))) { xmlnode_insert_child(message, child); } else { - purple_debug(PURPLE_DEBUG_ERROR, "jabber", + purple_debug_error("jabber", "XHTML translation/validation failed, returning: %s\n", jm->xhtml); }
--- a/libpurple/protocols/jabber/oob.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/oob.c Fri Nov 06 08:39:49 2009 +0000 @@ -95,7 +95,7 @@ if(len < 0 && errno == EAGAIN) return; else if(len < 0) { - purple_debug(PURPLE_DEBUG_ERROR, "jabber", "Write error on oob xfer!\n"); + purple_debug_error("jabber", "Write error on oob xfer!\n"); purple_input_remove(jox->writeh); purple_xfer_cancel_local(xfer); } @@ -150,7 +150,7 @@ } return 0; } else if (errno != EAGAIN) { - purple_debug(PURPLE_DEBUG_ERROR, "jabber", "Read error on oob xfer!\n"); + purple_debug_error("jabber", "Read error on oob xfer!\n"); purple_xfer_cancel_local(xfer); }
--- a/libpurple/protocols/jabber/si.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/si.c Fri Nov 06 08:39:49 2009 +0000 @@ -1349,7 +1349,7 @@ jabber_ibb_session_close(jsx->ibb_session); } jabber_si_xfer_free(xfer); - purple_debug(PURPLE_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_send\n"); + purple_debug_info("jabber", "in jabber_si_xfer_cancel_send\n"); } @@ -1381,7 +1381,7 @@ } jabber_si_xfer_free(xfer); - purple_debug(PURPLE_DEBUG_INFO, "jabber", "in jabber_si_xfer_request_denied\n"); + purple_debug_info("jabber", "in jabber_si_xfer_request_denied\n"); } @@ -1393,7 +1393,7 @@ jabber_ibb_session_close(jsx->ibb_session); } jabber_si_xfer_free(xfer); - purple_debug(PURPLE_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_recv\n"); + purple_debug_info("jabber", "in jabber_si_xfer_cancel_recv\n"); }
--- a/libpurple/protocols/jabber/useravatar.c Fri Nov 06 08:14:53 2009 +0000 +++ b/libpurple/protocols/jabber/useravatar.c Fri Nov 06 08:39:49 2009 +0000 @@ -262,7 +262,7 @@ gpointer icon_data; if(!url_text) { - purple_debug(PURPLE_DEBUG_ERROR, "jabber", + purple_debug_error("jabber", "do_buddy_avatar_update_fromurl got error \"%s\"", error_message); goto out;