/pidgin/main: b61329019afe: Ad a check to make sure that connect...

Daniel Atallah <[email protected]>
Newsgroups gmane.comp.gnome.gaim.cvs
Message-ID <[email protected]>
Changeset: b61329019afe03b4a3140df787168cfbaa98a397
Author:	 Daniel Atallah <[email protected]>
Date:	 2015-06-10 21:00 -0400
Branch:	 release-2.x.y
URL: https://hg.pidgin.im/pidgin/main/rev/b61329019afe

Description:

Ad a check to make sure that connect_data is valid before freeing it to avoid double-frees

 * Fixes #16536

diffstat:

 libpurple/proxy.c |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (13 lines):

diff --git a/libpurple/proxy.c b/libpurple/proxy.c
--- a/libpurple/proxy.c
+++ b/libpurple/proxy.c
@@ -568,6 +568,9 @@ purple_win32_proxy_get_info(void)
 static void
 purple_proxy_connect_data_destroy(PurpleProxyConnectData *connect_data)
 {
+	if (!PURPLE_PROXY_CONNECT_DATA_IS_VALID(connect_data))
+		return;
+
 	handles = g_slist_remove(handles, connect_data);
 
 	if (connect_data->query_data != NULL)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.