Only in ./: account.o
Only in ./: bitlbee
Only in ./: bitlbee.o
Only in ./: commands.o
Only in ./: config.h
Only in ./: conf.o
Only in ./: crypting.o
Only in ./: diff
Only in ./: help.o
Only in ./: ini.o
diff -ur ../bitlbee-1.0.3-original/irc.c ./irc.c
|
old
|
new
|
|
| 116 | 116 | set_add( irc, "buddy_sendbuffer", "false", set_eval_bool ); |
| 117 | 117 | set_add( irc, "buddy_sendbuffer_delay", "200", set_eval_int ); |
| 118 | 118 | set_add( irc, "charset", "iso8859-1", set_eval_charset ); |
| | 119 | set_add( irc, "oscar_recode_charset", "iso8859-1", set_eval_oscar_recode_charset ); |
| 119 | 120 | set_add( irc, "debug", "false", set_eval_bool ); |
| 120 | 121 | set_add( irc, "default_target", "root", NULL ); |
| 121 | 122 | set_add( irc, "display_namechanges", "false", set_eval_bool ); |
Only in ./: irc.o
Only in ./: log.o
Only in ./: Makefile.settings
Only in ./: nick.o
Only in ./protocols/jabber: expat.o
Only in ./protocols/jabber: hashtable.o
Only in ./protocols/jabber: jabber_mod.o
Only in ./protocols/jabber: jabber.o
Only in ./protocols/jabber: jid.o
Only in ./protocols/jabber: jpacket.o
Only in ./protocols/jabber: jutil.o
Only in ./protocols/jabber: log.o
Only in ./protocols/jabber: pool.o
Only in ./protocols/jabber: str.o
Only in ./protocols/jabber: xmlnode.o
Only in ./protocols/jabber: xmlparse.o
Only in ./protocols/jabber: xmlrole.o
Only in ./protocols/jabber: xmltok.o
Only in ./protocols: md5.o
Only in ./protocols: nogaim.o
Only in ./protocols/oscar: admin.o
Only in ./protocols/oscar: auth.o
Only in ./protocols/oscar: bos.o
Only in ./protocols/oscar: buddylist.o
Only in ./protocols/oscar: chatnav.o
Only in ./protocols/oscar: chat.o
Only in ./protocols/oscar: conn.o
Only in ./protocols/oscar: icq.o
Only in ./protocols/oscar: im.o
Only in ./protocols/oscar: info.o
Only in ./protocols/oscar: misc.o
Only in ./protocols/oscar: msgcookie.o
diff -ur ../bitlbee-1.0.3-original/protocols/oscar/oscar.c ./protocols/oscar/oscar.c
|
old
|
new
|
|
| 1029 | 1029 | return 1; |
| 1030 | 1030 | } |
| 1031 | 1031 | |
| | 1032 | extern GSList *irc_connection_list; |
| | 1033 | |
| 1032 | 1034 | static int incomingim_chan1(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch1_args *args) { |
| | 1035 | char *src=""; |
| 1033 | 1036 | char *tmp = g_malloc(BUF_LONG + 1); |
| 1034 | 1037 | struct gaim_connection *gc = sess->aux_data; |
| 1035 | 1038 | int flags = 0; |
| … |
… |
|
| 1038 | 1041 | flags |= IM_FLAG_AWAY; |
| 1039 | 1042 | |
| 1040 | 1043 | if ((args->icbmflags & AIM_IMFLAGS_UNICODE) || (args->icbmflags & AIM_IMFLAGS_ISO_8859_1)) { |
| 1041 | | char *src; |
| 1042 | 1044 | |
| 1043 | 1045 | if (args->icbmflags & AIM_IMFLAGS_UNICODE) |
| 1044 | 1046 | src = "UNICODEBIG"; |
| 1045 | 1047 | else |
| 1046 | | src = "ISO8859-1"; |
| | 1048 | { |
| | 1049 | char *cs; |
| | 1050 | irc_t *irc = (irc_t*)irc_connection_list->data; |
| | 1051 | if( ( cs = set_getstr( irc, "oscar_recode_charset" ) ) && ( g_strcasecmp( cs, "utf-8" ) != 0 ) ) |
| | 1052 | src = cs; |
| | 1053 | else |
| | 1054 | src = "iso8859-1"; |
| | 1055 | } |
| 1047 | 1056 | |
| 1048 | 1057 | /* Try to use iconv first to convert the message to UTF8 - which is what BitlBee expects */ |
| 1049 | 1058 | if (do_iconv(src, "UTF-8", args->msg, tmp, args->msglen, BUF_LONG) >= 0) { |
| … |
… |
|
| 1063 | 1072 | } |
| 1064 | 1073 | } |
| 1065 | 1074 | } else { |
| 1066 | | g_snprintf(tmp, BUF_LONG, "%s", args->msg); |
| | 1075 | char *cs; |
| | 1076 | irc_t *irc = (irc_t*)irc_connection_list->data; |
| | 1077 | if( ( cs = set_getstr( irc, "oscar_recode_charset" ) ) && ( g_strcasecmp( cs, "utf-8" ) != 0 ) ) |
| | 1078 | src = cs; |
| | 1079 | else |
| | 1080 | src = "iso8859-1"; |
| | 1081 | if (do_iconv(src, "UTF-8", args->msg, tmp, args->msglen, BUF_LONG) < 0) { |
| | 1082 | g_snprintf(tmp, BUF_LONG, "[1%s]%s", src, args->msg); |
| | 1083 | } |
| 1067 | 1084 | } |
| 1068 | | } else |
| 1069 | | g_snprintf(tmp, BUF_LONG, "%s", args->msg); |
| 1070 | | |
| | 1085 | } else { |
| | 1086 | char *cs; |
| | 1087 | irc_t *irc = (irc_t*)irc_connection_list->data; |
| | 1088 | if( ( cs = set_getstr( irc, "oscar_recode_charset" ) ) && ( g_strcasecmp( cs, "utf-8" ) != 0 ) ) |
| | 1089 | src = cs; |
| | 1090 | else |
| | 1091 | src = "iso8859-1"; |
| | 1092 | if (do_iconv(src, "UTF-8", args->msg, tmp, args->msglen, BUF_LONG) < 0) { |
| | 1093 | g_snprintf(tmp, BUF_LONG, "[2%s]%s", src, args->msg); |
| | 1094 | } |
| | 1095 | } |
| | 1096 | |
| 1071 | 1097 | strip_linefeed(tmp); |
| 1072 | 1098 | serv_got_im(gc, userinfo->sn, tmp, flags, time(NULL), -1); |
| 1073 | 1099 | g_free(tmp); |
| … |
… |
|
| 1768 | 1794 | char sender[32]; |
| 1769 | 1795 | char *dialog_msg = g_strdup(msg->msg); |
| 1770 | 1796 | time_t t = get_time(msg->year, msg->month, msg->day, msg->hour, msg->minute, 0); |
| | 1797 | char *tmp = g_malloc(BUF_LONG + 1); |
| | 1798 | char *src = ""; |
| | 1799 | char *cs; |
| | 1800 | irc_t *irc = (irc_t*)irc_connection_list->data; |
| | 1801 | if( ( cs = set_getstr( irc, "oscar_recode_charset" ) ) && ( g_strcasecmp( cs, "utf-8" ) != 0 ) ) |
| | 1802 | src = cs; |
| | 1803 | else |
| | 1804 | src = "iso8859-1"; |
| 1771 | 1805 | g_snprintf(sender, sizeof(sender), "%u", msg->sender); |
| 1772 | 1806 | strip_linefeed(dialog_msg); |
| 1773 | | serv_got_im(gc, sender, dialog_msg, 0, t, -1); |
| | 1807 | if (do_iconv(src, "UTF-8", dialog_msg, tmp, strlen (msg->msg), BUF_LONG) < 0) |
| | 1808 | tmp = dialog_msg; |
| | 1809 | serv_got_im(gc, sender, tmp, 0, t, -1); |
| | 1810 | if (dialog_msg != tmp) |
| | 1811 | g_free (tmp); |
| 1774 | 1812 | g_free(dialog_msg); |
| 1775 | 1813 | } break; |
| 1776 | 1814 | |
| … |
… |
|
| 1838 | 1876 | } else { |
| 1839 | 1877 | struct aim_sendimext_args args; |
| 1840 | 1878 | char *s; |
| | 1879 | char *cs; |
| | 1880 | char *src=""; |
| | 1881 | irc_t *irc = (irc_t*)irc_connection_list->data; |
| | 1882 | if( ( cs = set_getstr( irc, "oscar_recode_charset" ) ) && ( g_strcasecmp( cs, "utf-8" ) != 0 ) ) |
| | 1883 | src = cs; |
| | 1884 | else |
| | 1885 | src = "iso8859-1"; |
| | 1886 | |
| 1841 | 1887 | |
| 1842 | 1888 | args.flags = AIM_IMFLAGS_ACK; |
| 1843 | 1889 | if (odata->icq) |
| … |
… |
|
| 1851 | 1897 | s = g_malloc(BUF_LONG); |
| 1852 | 1898 | /* Try if we can put it in an ISO8859-1 string first. |
| 1853 | 1899 | If we can't, fall back to UTF16. */ |
| 1854 | | if ((ret = do_iconv("UTF-8", "ISO8859-1", message, s, len, BUF_LONG)) >= 0) { |
| | 1900 | if ((ret = do_iconv("UTF-8", src, message, s, len, BUF_LONG)) >= 0) { |
| 1855 | 1901 | args.flags |= AIM_IMFLAGS_ISO_8859_1; |
| 1856 | 1902 | len = ret; |
| 1857 | 1903 | } else if ((ret = do_iconv("UTF-8", "UNICODEBIG", message, s, len, BUF_LONG)) >= 0) { |
| … |
… |
|
| 1863 | 1909 | s = message; |
| 1864 | 1910 | } |
| 1865 | 1911 | } else { |
| | 1912 | fprintf (stderr, "outgoing message is ascii!\n"); |
| 1866 | 1913 | s = message; |
| 1867 | 1914 | } |
| 1868 | 1915 | |
Only in ./protocols/oscar: oscar_mod.o
Only in ./protocols/oscar: oscar.o
Only in ./protocols/oscar: oscar_util.o
Only in ./protocols/oscar: rxhandlers.o
Only in ./protocols/oscar: rxqueue.o
Only in ./protocols/oscar: search.o
Only in ./protocols/oscar: service.o
Only in ./protocols/oscar: snac.o
Only in ./protocols/oscar: ssi.o
Only in ./protocols/oscar: stats.o
Only in ./protocols/oscar: tlv.o
Only in ./protocols/oscar: txqueue.o
Only in ./protocols: protocols.o
Only in ./protocols: proxy.o
Only in ./protocols: sha.o
Only in ./protocols: ssl_gnutls.o
Only in ./: query.o
Only in ./: set.o
Only in ./: unix.o
Only in ./: url.o
Only in ./: user.o
diff -ur ../bitlbee-1.0.3-original/util.c ./util.c
|
old
|
new
|
|
| 453 | 453 | iconv_close( cd ); |
| 454 | 454 | return( value ); |
| 455 | 455 | } |
| | 456 | |
| | 457 | char *set_eval_oscar_recode_charset( irc_t *irc, set_t *set, char *value ) |
| | 458 | { |
| | 459 | iconv_t cd; |
| | 460 | |
| | 461 | if ( g_strncasecmp( value, "none", 4 ) == 0 ) |
| | 462 | return( value ); |
| | 463 | |
| | 464 | cd = iconv_open( "UTF-8", value ); |
| | 465 | if( cd == (iconv_t) -1 ) |
| | 466 | return( NULL ); |
| | 467 | |
| | 468 | iconv_close( cd ); |
| | 469 | return( value ); |
| | 470 | } |
diff -ur ../bitlbee-1.0.3-original/util.h ./util.h
|
old
|
new
|
|
| 46 | 46 | |
| 47 | 47 | G_MODULE_EXPORT signed int do_iconv( char *from_cs, char *to_cs, char *src, char *dst, size_t size, size_t maxbuf ); |
| 48 | 48 | char *set_eval_charset( irc_t *irc, set_t *set, char *value ); |
| | 49 | char *set_eval_oscar_recode_charset( irc_t *irc, set_t *set, char *value ); |
| 49 | 50 | |
| 50 | 51 | #endif |