Merge pull request #1 from import/pidgin:rosa2012.1

Синхронизация с основной веткой.
This commit is contained in:
djam 2014-04-03 21:38:15 +04:00
commit 3306dac5cb
9 changed files with 223 additions and 984 deletions

View file

@ -1,2 +1,4 @@
removed_sources:
pidgin-2.10.6.tar.bz2: a0532e7ba2acd205d6a5a4e3624156a980fe3d43
sources:
"pidgin-2.10.2.tar.bz2": 5ec0a8a51a9d237f1eaf27bf8858599e8fa6ecce
pidgin-2.10.7.tar.bz2: 01bc06e3a5712dded3ad4a4913ada12a3cd01e15

View file

@ -1,16 +1,15 @@
--- pidgin-2.10.0/libpurple/protocols/gg/gg.c.gg-search 2011-08-18 10:51:03.000000000 +0200
+++ pidgin-2.10.0/libpurple/protocols/gg/gg.c 2011-08-22 15:57:02.000000000 +0200
@@ -533,6 +533,9 @@ static void ggp_callback_find_buddies(Pu
--- pidgin-2.10.0/libpurple/protocols/gg/gg.c.orig 2011-08-18 10:51:03.000000000 +0200
+++ pidgin-2.10.0/libpurple/protocols/gg/gg.c 2011-08-21 09:54:41.000000000 +0200
@@ -533,6 +533,8 @@
purple_request_fields_get_string(fields, "firstname"));
form->nickname = g_strdup(
purple_request_fields_get_string(fields, "nickname"));
+ form->uin = charset_convert(
+ purple_request_fields_get_string(fields, "uin"),
+ "UTF-8", "CP1250");
+ form->uin = g_strdup(
+ purple_request_fields_get_string(fields, "uin"));
form->city = g_strdup(
purple_request_fields_get_string(fields, "city"));
form->birthyear = g_strdup(
@@ -586,6 +589,11 @@ static void ggp_find_buddies(PurplePlugi
@@ -586,6 +588,11 @@
purple_request_field_string_set_masked(field, FALSE);
purple_request_field_group_add_field(group, field);

View file

@ -0,0 +1,32 @@
--- pidgin-2.10.1/libpurple/Makefile.am~ 2011-12-06 09:44:33.000000000 +0100
+++ pidgin-2.10.1/libpurple/Makefile.am 2011-12-13 17:14:37.492942189 +0100
@@ -32,7 +32,7 @@ endif
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = purple.pc
-SUBDIRS = $(GCONF_DIR) plugins protocols ciphers . tests example
+SUBDIRS = $(GCONF_DIR) protocols ciphers . plugins tests example
purple_coresources = \
account.c \
--- pidgin-2.10.1/libpurple/plugins/perl/Makefile.am~ 2011-12-06 09:44:33.000000000 +0100
+++ pidgin-2.10.1/libpurple/plugins/perl/Makefile.am 2011-12-13 17:15:09.437943687 +0100
@@ -5,7 +5,7 @@ perl_dirs = common
plugin_LTLIBRARIES = perl.la
perl_la_LDFLAGS = -module -avoid-version
-perl_la_LIBADD = $(GLIB_LIBS) $(PERL_LIBS)
+perl_la_LIBADD = $(GLIB_LIBS) $(PERL_LIBS) $(top_builddir)/libpurple/libpurple.la
perl_la_SOURCES = \
perl.c \
perl-common.c \
@@ -15,7 +15,8 @@ perl_la_SOURCES = \
perl_la_DEPENDENCIES = \
.libs/libperl_orig.a \
- .libs/DynaLoader.a
+ .libs/DynaLoader.a \
+ $(top_builddir)/libpurple/libpurple.la
.libs/libperl_orig.a:
@mkdir -p .libs

View file

@ -0,0 +1,22 @@
--- pidgin-2.10.2/libpurple/protocols/jabber/Makefile.am.soname~ 2012-03-16 20:23:40.918123912 +0100
+++ pidgin-2.10.2/libpurple/protocols/jabber/Makefile.am 2012-03-16 20:24:42.355199920 +0100
@@ -93,7 +93,7 @@ JABBERSOURCES = \
AM_CFLAGS = $(st)
-libjabber_la_LDFLAGS = -module -avoid-version
+libjabber_la_LDFLAGS = -module -avoid-version -Wl,-soname=libjabber.so
libxmpp_la_LDFLAGS = -module -avoid-version
if USE_CYRUS_SASL
--- pidgin-2.10.2/libpurple/protocols/oscar/Makefile.am.soname~ 2012-03-16 20:15:58.733552100 +0100
+++ pidgin-2.10.2/libpurple/protocols/oscar/Makefile.am 2012-03-16 20:15:58.753552126 +0100
@@ -52,7 +52,7 @@ AM_CFLAGS = $(st)
libaim_la_LDFLAGS = -module -avoid-version
libicq_la_LDFLAGS = -module -avoid-version
-liboscar_la_LDFLAGS = -module -avoid-version
+liboscar_la_LDFLAGS = -module -avoid-version -Wl,-soname=liboscar.so
if STATIC_OSCAR
st = -DPURPLE_STATIC_PRPL

View file

@ -1,5 +1,5 @@
--- pidgin-2.8.0/libpurple/network.c.reread-resolvconf 2011-06-07 10:44:40.000000000 +0200
+++ pidgin-2.8.0/libpurple/network.c 2011-06-08 03:09:18.000000000 +0200
--- pidgin-2.8.0/libpurple/network.c.reread-resolvconf 2011-06-09 16:30:04.764927571 +0200
+++ pidgin-2.8.0/libpurple/network.c 2011-06-09 16:31:29.356249181 +0200
@@ -874,8 +874,6 @@
#else
case NM_STATE_CONNECTED:

View file

@ -1,75 +0,0 @@
#
#
# patch "libpurple/proxy.c"
# from [2a1922d6f3744bc61c81543909324d38d741948f]
# to [df78b061b3bc73de02f1a4ad29357497322aaf89]
#
============================================================
--- libpurple/proxy.c 2a1922d6f3744bc61c81543909324d38d741948f
+++ libpurple/proxy.c df78b061b3bc73de02f1a4ad29357497322aaf89
@@ -59,6 +59,8 @@ struct _PurpleProxyConnectData {
*/
GSList *hosts;
+ PurpleProxyConnectData *child;
+
/*
* All of the following variables are used when establishing a
* connection through a proxy.
@@ -559,6 +561,12 @@ purple_proxy_connect_data_disconnect(Pur
static void
purple_proxy_connect_data_disconnect(PurpleProxyConnectData *connect_data, const gchar *error_message)
{
+ if (connect_data->child != NULL)
+ {
+ purple_proxy_connect_cancel(connect_data->child);
+ connect_data->child = NULL;
+ }
+
if (connect_data->inpa > 0)
{
purple_input_remove(connect_data->inpa);
@@ -2417,13 +2425,20 @@ static void socks5_connected_to_proxy(gp
/* This is the PurpleProxyConnectData for the overall SOCKS5 connection */
PurpleProxyConnectData *connect_data = data;
+ purple_debug_error("proxy", "Connect Data is %p\n", connect_data);
+
/* Check that the overall SOCKS5 connection wasn't cancelled while we were
* connecting to it (we don't have a way of associating the process of
* connecting to the SOCKS5 server to the overall PurpleProxyConnectData)
*/
- if (!PURPLE_PROXY_CONNECT_DATA_IS_VALID(connect_data))
+ if (!PURPLE_PROXY_CONNECT_DATA_IS_VALID(connect_data)) {
+ purple_debug_error("proxy", "Data had gone out of scope :(\n");
return;
+ }
+ /* Break the link between the two PurpleProxyConnectDatas */
+ connect_data->child = NULL;
+
if (error_message != NULL) {
purple_debug_error("proxy", "Unable to connect to SOCKS5 host.\n");
connect_data->connect_cb(connect_data->data, source, error_message);
@@ -2486,10 +2501,7 @@ purple_proxy_connect_socks5_account(void
return NULL;
}
- /* The API doesn't really provide us with a way to cancel the specific
- * proxy connection attempt (account_proxy_conn_data) when the overall
- * SOCKS5 connection (connect_data) attempt is cancelled :(
- */
+ connect_data->child = account_proxy_conn_data;
handles = g_slist_prepend(handles, connect_data);
@@ -2499,6 +2511,8 @@ purple_proxy_connect_cancel(PurpleProxyC
void
purple_proxy_connect_cancel(PurpleProxyConnectData *connect_data)
{
+ g_return_if_fail(connect_data != NULL);
+
purple_proxy_connect_data_disconnect(connect_data, NULL);
purple_proxy_connect_data_destroy(connect_data);
}

View file

@ -1,64 +0,0 @@
#
#
# patch "libpurple/protocols/msn/msg.c"
# from [94fe3963ccab9a56f0311277c241efbc0242a4d6]
# to [417ae5cb2f85d578b7e00fcb9c450dad1171c499]
#
============================================================
--- libpurple/protocols/msn/msg.c 94fe3963ccab9a56f0311277c241efbc0242a4d6
+++ libpurple/protocols/msn/msg.c 417ae5cb2f85d578b7e00fcb9c450dad1171c499
@@ -257,13 +257,47 @@ msn_message_parse_payload(MsnMessage *ms
msg->body[msg->body_len] = '\0';
}
- if ((!content_type || !strcmp(content_type, "text/plain"))
- && msg->charset == NULL) {
- char *body = g_convert(msg->body, msg->body_len, "UTF-8",
- "ISO-8859-1", NULL, &msg->body_len, NULL);
- g_free(msg->body);
- msg->body = body;
- msg->charset = g_strdup("UTF-8");
+ if (msg->body && content_type && purple_str_has_prefix(content_type, "text/")) {
+ char *body = NULL;
+
+ if (msg->charset == NULL || g_str_equal(msg->charset, "UTF-8")) {
+ /* Charset is UTF-8 */
+ if (!g_utf8_validate(msg->body, msg->body_len, NULL)) {
+ purple_debug_warning("msn", "Message contains invalid "
+ "UTF-8. Attempting to salvage.\n");
+ body = purple_utf8_salvage(msg->body);
+ payload_len = strlen(body);
+ }
+ } else {
+ /* Charset is something other than UTF-8 */
+ GError *err = NULL;
+ body = g_convert(msg->body, msg->body_len, "UTF-8",
+ msg->charset, NULL, &payload_len, &err);
+ if (!body || err) {
+ purple_debug_warning("msn", "Unable to convert message from "
+ "%s to UTF-8: %s\n", msg->charset,
+ err ? err->message : "Unknown error");
+ if (err)
+ g_error_free(err);
+
+ /* Fallback to ISO-8859-1 */
+ g_free(body);
+ body = g_convert(msg->body, msg->body_len, "UTF-8",
+ "ISO-8859-1", NULL, &payload_len, NULL);
+ if (!body) {
+ g_free(msg->body);
+ msg->body = NULL;
+ msg->body_len = 0;
+ }
+ }
+ }
+
+ if (body) {
+ g_free(msg->body);
+ msg->body = body;
+ msg->body_len = payload_len;
+ msn_message_set_charset(msg, "UTF-8");
+ }
}
g_free(tmp_base);

File diff suppressed because it is too large Load diff