# HG changeset patch # User Nathan Walp # Date 1043779025 0 # Node ID 2f225b92a93347a9e2ec22fa8af05cde6dd3142c # Parent faa9b636707af748590ed064ba771e1da6ce2eeb [gaim-migrate @ 4725] sean puts up really long away messages. that reminded me that jabber doesn't show linebreaks in away messages correctly I also removed the "gjab_send_raw: \t " lines from the debug window, because they're useless and annoying. committer: Tailor Script diff -r faa9b636707a -r 2f225b92a933 src/protocols/jabber/jabber.c --- a/src/protocols/jabber/jabber.c Tue Jan 28 16:57:58 2003 +0000 +++ b/src/protocols/jabber/jabber.c Tue Jan 28 18:37:05 2003 +0000 @@ -98,6 +98,8 @@ #define JABBER_TYPING_NOTIFY_INT 15 /* Delay (in seconds) between sending typing notifications */ +#define JABBER_KEEPALIVE_STRING " \t " + /* * Note: "was_connected" may seem redundant, but it was needed and I * didn't want to touch the Jabber state stuff not specific to Gaim. @@ -579,7 +581,9 @@ fprintf(stderr, "DBG: Problem sending. Error: %d\n", errno); fflush(stderr); } - debug_printf("gjab_send_raw: %s\n", str); + /* printing keepalives to the debug window is really annoying */ + if(strcmp(str, JABBER_KEEPALIVE_STRING)) + debug_printf("gjab_send_raw: %s\n", str); } } @@ -3184,9 +3188,12 @@ for(i=0; idata; + char *status; realwho = g_strdup_printf("%s/%s", buddy, jri->name); + status = strdup_withhtml(jabber_lookup_away(gjc, realwho)); *ap++ = g_strdup_printf("Jabber ID: %s
\n", realwho); - *ap++ = g_strdup_printf("Status: %s
\n", jabber_lookup_away(gjc, realwho)); + *ap++ = g_strdup_printf("Status: %s
\n", status); + g_free(status); g_free(realwho); resources = resources->next; } @@ -3405,7 +3412,7 @@ static void jabber_keepalive(struct gaim_connection *gc) { struct jabber_data *jd = (struct jabber_data *)gc->proto_data; - gjab_send_raw(jd->gjc, " \t "); + gjab_send_raw(jd->gjc, JABBER_KEEPALIVE_STRING); } /*---------------------------------------*/ @@ -3586,9 +3593,9 @@ } } - status = jabber_lookup_away(gjc, buddy); - + status = strdup_withhtml(jabber_lookup_away(gjc, buddy)); *ap++ = g_strdup_printf("Status: %s
\n", status); + g_free(status); /* * "Description" handled as a special case: get a copy of the