# HG changeset patch # User Mark Doliner # Date 1102196485 0 # Node ID fcadde998ba92e1a0ea9fd040b6298e6325a2468 # Parent 2b0f39e264ea687e5a86570d8f681bd1ad697a47 [gaim-migrate @ 11520] Hopefully decode non-ascii direct IM messages. committer: Tailor Script diff -r 2b0f39e264ea -r fcadde998ba9 COPYRIGHT --- a/COPYRIGHT Sat Dec 04 21:30:03 2004 +0000 +++ b/COPYRIGHT Sat Dec 04 21:41:25 2004 +0000 @@ -147,6 +147,7 @@ Alceste Scalas Carsten Schaar Luke Schierer +Ralph Schmieder Evan Schoenberg Torrey Searle Don Seiler diff -r 2b0f39e264ea -r fcadde998ba9 src/protocols/oscar/oscar.c --- a/src/protocols/oscar/oscar.c Sat Dec 04 21:30:03 2004 +0000 +++ b/src/protocols/oscar/oscar.c Sat Dec 04 21:41:25 2004 +0000 @@ -1296,10 +1296,15 @@ g_string_append_len(newmsg, msg, len); } - /* XXX - I imagine Paco-Paco will want to do some voodoo with the encoding here */ - serv_got_im(gc, sn, newmsg->str, imflags, time(NULL)); - - /* free up the message */ + /* Convert to UTF8 */ + /* (This hasn't been tested very much) */ + utf8 = gaim_plugin_oscar_decode_im_part(gc->account, sn, encoding, 0x0000, newmsg->str, len); + if (utf8 != NULL) { + serv_got_im(gc, sn, utf8, imflags, time(NULL)); + g_free(utf8); + } + + /* free the message */ g_string_free(newmsg, TRUE); /* unref any images we allocated */